I thought it was interesting that the money works and decimal does not. I did a little more testing. Based on that testing, I would almost say that the ISNULL check implicitly converts the string to a float(or money) for the money data type for the comparison but does not do that for the decimal.
DECLARE @integer INT
,@Float FLOAT
,@Decimal DECIMAL(18,6)
,@Bit BIT
,@Money MONEY
,@String VARCHAR(20) = CAST('' AS FLOAT)
SELECT ISNULL(@Integer,@String),'Int'
SELECT ISNULL(@Float,@String),'Float'
SELECT ISNULL(@Decimal,@String),'Decimal'
SELECT ISNULL(@Bit,@String),'Bit'
SELECT ISNULL(@Money,@String),'Money'
It makes no sense that the decimal behaves this way when the money doesn't.
Jason...AKA CirqueDeSQLeil
_______________________________________________
I have given a name to my pain...MCM SQL Server, MVP
SQL RNNR
Posting Performance Based Questions - Gail Shaw[/url]
Learn Extended Events