Tuesday, August 12, 2008

[GENERAL] differnt behaviour of NULL in an aggregate and with an operator

Hi,

Why is it that
  SELECT 1+null
evaluates to NULL, but
  SELECT sum(foo) FROM (VALUES(1), (NULL)) AS v(foo)
evaluates to 1 ?

WBL

No comments: