Mittwoch, 10. Oktober 2007

Oracle 10g - hidden function with "is null"

after some features in Rave I'll blog today about an undocumented feature in Oracle 10g ...

Every database-developer know the sql-statement "where column IS NULL", no problem I think
BUT how can you extend the statement into "where column1 IS NULL = column2 I IS NULL" ??
This type of query is IMO not defined in the SQL-standard or possible with a SQL-database, or ?

In Oracle 10g is an undocumented function: sys_op_map_nonnull

...where sys_op_map_nonnull(column1)=sys_op_map_nonnull(column2) ...

this makes sometimes my developer-life easier

Keine Kommentare: