Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

format numeric field

2 posts in General Discussion Last posting was on 2004-06-09 13:29:01.0Z
wissam aoufan Posted on 2004-06-05 08:11:10.0Z
From: "wissam aoufan" <waoufan@lb.path-solutions.com>
Newsgroups: ianywhere.public.general
Subject: format numeric field
Lines: 14
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
X-Original-NNTP-Posting-Host: 194.126.1.148
Message-ID: <40c18069@forums-2-dub>
X-Original-Trace: 5 Jun 2004 01:12:25 -0700, 194.126.1.148
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 5 Jun 2004 01:09:03 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 5 Jun 2004 01:11:10 -0700
X-Trace: forums-1-dub 1086423070 10.22.108.75 (5 Jun 2004 01:11:10 -0700)
X-Original-Trace: 5 Jun 2004 01:11:10 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:3109
Article PK: 6570

Hi

i donno how to format a numeric field in ASA.

ex . i want a numeric column containing a value 123000 to appear in this
format 123,000.00 . i tried the convert(money,123000) and it didn't work .

note that i'm using sybase adaptive server anywhere ISQL version 8.0.2
build 3601

thanx.


David Fishburn Posted on 2004-06-09 13:29:01.0Z
Newsgroups: ianywhere.public.general
Subject: Re: format numeric field
From: David Fishburn <fishburn_spam_off@ianywhere.com>
References: <40c18069@forums-2-dub>
Organization: iAnywhere Solutions
Message-ID: <Xns9503600C92E75fishburnsybasecom@10.22.241.106>
User-Agent: Xnews/06.08.25
NNTP-Posting-Host: vpn-concord-010.sybase.com
X-Original-NNTP-Posting-Host: vpn-concord-010.sybase.com
Date: 9 Jun 2004 06:29:01 -0700
X-Trace: forums-1-dub 1086787741 158.159.8.10 (9 Jun 2004 06:29:01 -0700)
X-Original-Trace: 9 Jun 2004 06:29:01 -0700, vpn-concord-010.sybase.com
Lines: 36
X-Authenticated-User: techsupp
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.general:3131
Article PK: 6589

"wissam aoufan" <waoufan@lb.path-solutions.com> wrote in
news:40c18069@forums-2-dub:

wa> ex . i want a numeric column containing a value 123000 to appear in
wa> this format 123,000.00 . i tried the convert(money,123000) and it
wa> didn't work .

There is no way that I am familiar with.
You could always write you own function that formatted it and you did:
select f_MyNumFormatter(col2)
from t1

But of course, the value comes back as a string.

Normally the frontend application takes care of "formatting".
--
David Fishburn
Certified ASA Developer Version 8
iAnywhere Solutions - Sybase
Professional Services
Please only post to the newsgroup
Please ALWAYS include version and MORE importantly BUILD number with
EACH post (dbeng9 -v).

EBFs and Maintenance Releases
http://downloads.sybase.com/swx/sdmain.stm

Developer Community / Whitepapers
http://www.ianywhere.com/developer

CaseXpress - to report bugs
http://casexpress.sybase.com

CodeXchange - Free samples
http://ianywhere.codexchange.sybase.com/servlets/ProjectDocumentList