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

Implicit conversion using COALESCE or CASE Expand / Collapse
Author
Message
Posted Friday, July 05, 2013 1:30 PM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Today @ 12:59 PM
Points: 1,734, Visits: 2,534
ISNULL() has its own oddities:


DECLARE @var1 char(1)
SET @var1 = NULL

SELECT ISNULL(@var1, 'N/A') -- Result = 'N'




SQL DBA,SQL Server MVP('07, '08, '09)
I'm not fat, I'm gravity challenged.
Post #1470865
Posted Friday, July 05, 2013 1:54 PM


Right there with Babe

Right there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with BabeRight there with Babe

Group: General Forum Members
Last Login: Yesterday @ 7:33 AM
Points: 755, Visits: 629
Yes, the data type for isnull is always the type of the first argument.

Erland Sommarskog, SQL Server MVP, www.sommarskog.se
Post #1470871
« Prev Topic | Next Topic »

Add to briefcase ««12

Permissions Expand / Collapse