as we know, Teradata provides the well-known method NULLIFZERO.
Teradata also privides us another method named 'NULLIF', that's more powerfull, more flexible,
can be used to replace some query like
CASE WHEN COL1 = VALUE1 THEN NULL ELSE COL1
simply to
NULLIF(COL1, VALUE1)
http://forums.teradata.com/forum/database/coalesce
与广为人知的NULLIFZERO相比,TERADATA提供的NULLIF功能就不那么常用了,其实NULLIF功能更强大,更灵活,某些情况下能被用来简化,替换掉一些CASE语句
如上
No comments:
Post a Comment