MarkLogic 9 Product Documentation
sql:nullif

sql:nullif(
   $expr1 as item()*,
   $expr2 as item()*
) as item()*

Summary

Returns a NULL value if the two specified values are equal. Returns the first value if they are not equal

Parameters
expr1 First expression to be evaluated.
expr2 Second expression to be evaluated.

Example

sql:nullif(1,1) 
=>
NULL
Powered by MarkLogic Server | Terms of Use | Privacy Policy