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 «««123

Coalesce and Conversion Expand / Collapse
Author
Message
Posted Wednesday, January 09, 2013 6:51 PM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Today @ 7:16 AM
Points: 1,216, Visits: 234
Great QoTD..
Thanks..
Post #1405114
Posted Thursday, January 10, 2013 10:47 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 10:53 AM
Points: 7,099, Visits: 7,159
john.arnott (1/8/2013)
How annoying. You made me think! ;)

I agree this was an excellent question and explanation. I do see that one minor correction could be needed to one example given, however. You say "...for example the numeric value 37.2 can be converted to an int (37)...". Did you actually mean that an INT (@i) could be converted to the higher precedence numeric type, as obviously could be the literal value 37.2? After all, the result of that coalesce is 37.2 and not 37.

yes, I did. Obviously my check-reading what I had written wasn't up to scratch that day.


Tom
Que conclure à la fin de tous mes longs propos? C'est que les préjugés sont la raison des sots. (Voltaire, 1756)
Post #1405559
Posted Friday, January 11, 2013 11:53 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Yesterday @ 12:18 AM
Points: 152, Visits: 155
really very tough one...

Manik
You cannot get to the top by sitting on your bottom.
Post #1406213
Posted Saturday, February 02, 2013 3:20 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Saturday, February 02, 2013 5:42 AM
Points: 190, Visits: 74
I got the result by executing the each statement :)
Post #1414933
« Prev Topic | Next Topic »

Add to briefcase «««123

Permissions Expand / Collapse