


Expression is NOT NULL so the result is NULL.Expression is NOT false so the result is TRUE.Expression is NOT true so the result is FALSE.One expression is false and another expression is NULL so the result is NULL.One expression is true and another expression is NULL, so the result is TRUE.One expression is true and another expression is false so the result is TRUE.Both expressions are NULL so the result is NULL.One expression is false and another expression is NULL, so the result is FALSE.Both expressions are false, so the result is FALSE.One expression is true and another expression is NULL, so the result is NULL.One expression is true and another expression is false, so the result is FALSE.Both expressions are true, so the result is TRUE.NOT = Reverses the value of Boolean operator. OR = if any boolean expression is true then it will return TRUE These boolean operators are used to match conditions in a SQL statement-e.g., in WHERE and HAVING clauses.ĪND = if both boolean expressions are true then it will return TRUE There are 3 logical operators available in PostgreSQL: Logical operators (also known as boolean operators) are used to estimate some set of conditions where the result can be TRUE, FALSE, or NULL (missing, unknown, unavailable, unassigned). The logical operators in PostgreSQL are AND, OR, and NOT.
#Not in postgresql how to#
SUMMARY: This article looks at logical operators in PostgreSQL and how to use them.
