Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

CONVERT DATATYPE Expand / Collapse
Author
Message
Posted Friday, November 19, 2010 1:53 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Thursday, August 30, 2012 1:40 AM
Points: 47, Visits: 150
How to convert Money data type to Decimal or Double . SQL 2005

Give me sample pls
Post #1023357
Posted Friday, November 19, 2010 2:14 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Thursday, August 30, 2012 1:40 AM
Points: 47, Visits: 150
Amount = money

select SUM(CAST(AMOUNT AS decimal(18,2))) FROM tableName
Post #1023360
Posted Friday, November 19, 2010 2:30 AM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Today @ 9:28 AM
Points: 13,570, Visits: 10,447
16 digits before the decimal separator, that sure is a lot of money

(I guess you have already solved the problem, as the statement that you provided should work)




How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?

Member of LinkedIn. My blog at LessThanDot.

MCSA SQL Server 2012 - MCSE Business Intelligence
Post #1023366
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse