Logical operators
Logical operators are used to combine two or more conditions to produce a single result. A row will be returned if the overall result of the condition is TRUE.
Type of Logical Operators
AND
OR
NOT
An example of each will be explained below;
Rules of precedence of Operators:
Precedence in which order the expressions are evaluated, you can override by using parentheses around the expressions.
Rules of Precedence
You can use parentheses to override rules of precedence.
1 Arithmetic operators
2 Concatenation operator
3 Comparison conditions
4 IS [NOT] NULL, LIKE, [NOT] IN
5 [NOT] BETWEEN
6 Not equal to
7 NOT logical operator
8 AND logical operator
9 OR logical operatoreani