Friday, December 28, 2012

Display Currency format in Sql Server


In Sql server 2008 and below there is no special method to show currency format. You will need to convert the money value into a varchar and append the currency format.

declare @tblTest table
(
 wallet money null
)

insert into @tblTest values(1000)
select '$'+convert(varchar,wallet) as price from @tblTest

Output:
price
$1000.00

No comments:
Write comments
Recommended Posts × +