











CompTIA
Exam Vouchers
Save money on CompTIA exams
| Question of the day
Sign up to receive
interactive practice questions
for MCSE, CompTIA
Cisco and other exams
| TestKing
Get MCSE, MCSD, CCNA, CCNP,A+, N+ and many more | * ExamSheets *
Guide for Success!
Actual Questions & Answers
MCSE, MCSD, A+ ,CCNA, CCNP
Oracle 8i, Oracle 9i Online practice tests
Certification sites Online university Online college Online education Distance learning Software forum Server administration forum Programming resources
|
|  |
| Author |
Formating number in SQL Analyzer output (thousands separator)
|
John Gooch
Guest
Registered: Not Yet Location: Country: State: Certifications: Working on:
Total Posts: N/A
|
|
Formating number in SQL Analyzer output (thousands separator)
Hi,
I have a big stored procedure that takes several minutes to run to make some
calculations.
At certain points I have code like the following
Print 'Assets Total : ' + Cast(@TotalAssets as VarChar(20))
This makes an out put
'Assets Total : 4565432135.23'
As you see, there is no thousands separator ...
How can I achieve this output : 'Assets Total : 4,565,432,135.23' ??
Thanks in advance
Report this post to a moderator
|
|
06-27-02 11:25 PM
|
|
Mikhail Berlyant
Guest
Registered: Not Yet Location: Country: State: Certifications: Working on:
Total Posts: N/A
|
|
Re: Formating number in SQL Analyzer output (thousands separator)
declare @val as money set @val = 4565432135.23
select convert(varchar(30),@val,1)
Mikhail Berlyant
Data Integrator, Data Systems
Launch Your Yahoo!Music Experience http://launch.yahoo.com
Brainbench MVP for Visual Basic www.brainbench.com
"John Gooch" <johngooch7@yahoo.com> wrote in message
news:3D1BA436.9000800@yahoo.com...
>
> Hi,
>
> I have a big stored procedure that takes several minutes to run to make
some
> calculations.
> At certain points I have code like the following
>
> Print 'Assets Total : ' + Cast(@TotalAssets as VarChar(20))
>
> This makes an out put
> 'Assets Total : 4565432135.23'
>
> As you see, there is no thousands separator ...
>
> How can I achieve this output : 'Assets Total : 4,565,432,135.23' ??
>
>
> Thanks in advance
>
Report this post to a moderator
|
|
06-27-02 11:25 PM
|
|
|
Featured site: MCSE, MCSD, CompTIA, CCNA training videos
Forum Rules: Who Can Read The Forum? Any registered user or guest.
Who Can Post New Topics? Any registered user.
Who Can Post Replies? Any registered user.
Changes: Messages can be edited by their author.
Posts: HTML code is OFF. Smilies are ON. vB code is ON. [IMG] code is OFF. |
|
ExamNotes forum archive
|