Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
Sun Foster
Aged Yak Warrior
515 Posts |
Posted - 2007-08-10 : 16:24:00
|
| Money field display like 59.6600.How to make 59.66? |
|
|
dinakar
Master Smack Fu Yak Hacker
2507 Posts |
Posted - 2007-08-10 : 17:31:22
|
Ashley's recommendation: http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=87689quote: Originally posted by ashley.sqlCREATE TABLE #Table1 (C1 money)INSERT INTO #Table1 VALUES(4.13)INSERT INTO #Table1 VALUES(4.24)INSERT INTO #Table1 VALUES(6.76)INSERT INTO #Table1 VALUES(5.17) INSERT INTO #Table1 VALUES(5.29) select convert(varchar(20),C1) from #table1
Dinakar Nethi************************Life is short. Enjoy it.************************http://weblogs.sqlteam.com/dinakar/ |
 |
|
|
dinakar
Master Smack Fu Yak Hacker
2507 Posts |
Posted - 2007-08-10 : 17:34:49
|
| But my recommendation would be:declare @d decimal (10,5)set @d = 59.6600select @d, convert(Decimal(10,2) , @d)Dinakar Nethi************************Life is short. Enjoy it.************************http://weblogs.sqlteam.com/dinakar/ |
 |
|
|
|
|
|