March 12, 2009 at 6:40 am
Hi all,
If my data is 1 I want it as 01.00
Like wise
1.0 --> 01.00
1.1 --> 01.10
10 --> 10.00
100 --> 100.00
Thanks.
Babu Kumarasamy
March 12, 2009 at 6:48 am
could you just
cast(@yournumber as money)
March 12, 2009 at 6:53 am
The best place to do formatting is the at the presentation layer. The fact that it can be done using SQL Server doesn’t mean that it should be done using t-sql. Having said that, here is one way of doing it, but I do recommend that you’ll use the presentation layer for this kind of tasks instead of SQL Server
select convert(varchar(10),convert(money,1))
Adi
--------------------------------------------------------------
To know how to ask questions and increase the chances of getting asnwers:
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply