Using operators with NULL values : Comparison Operators « Select Query « PostgreSQL






Using operators with NULL values


postgres=#
postgres=# -- Using operators with NULL values
postgres=#
postgres=# \pset null *null* Null display is '*null*'.
Null display is "*null*".
\pset: extra argument "Null" ignored
\pset: extra argument "display" ignored
\pset: extra argument "is" ignored
\pset: extra argument "*null*" ignored
\pset: extra argument "." ignored
postgres=#
postgres=# SELECT 5 > NULL;
 ?column?
----------
 *null*
(1 row)

postgres=#
postgres=# SELECT NULL IS NULL;
 ?column?
----------
 t
(1 row)

postgres=#
postgres=# SELECT NULL || 'Test';
 ?column?
----------
 *null*
(1 row)

postgres=#
postgres=#
           
       








Related examples in the same category

1.Using comparison operators
2.Combining comparisons with Boolean operators