sql WHERE clause with AND & OR
The SQL WHERE clause is used to display records that fulfills a specified condition.
The following is the syntax of the WHERE clause:
SELECT myColumn1, myColumn2, myColumn3
FROM myTable WHERE columnName operator value
The operator can either be , =, IS, ISNOT.
The value can be a string, numerical, NULL.
AND & OR Operator
The AND & OR operators are used to display records based on more than one condition.
The AND operator displays a record if both the first condition and the second condition is true.
The OR operator displays a record if either the first condition or the second condition is true.
SQL AND syntax
SELECT * FROM myTable
WHERE columnName operator value AND columnName operator value