Mark As Completed Discussion

One Pager Cheat Sheet

  • This tutorial introduces the WHERE keyword and other important keywords, LIKE, IN, BETWEEN, AND, OR, and NOT, to help filter data efficiently in SQL queries utilizing the Person table.
  • The LIKE operator is used to find specific patterns in the columns, using percent and underscore signs as wildcards.
  • The LIKE operator with % wildcard is used to retrieve all rows from the Person table where the Name column ends with "a".
  • The AND operator can be used to filter data by specifying multiple conditions in a SQL query, for example to get all customers living in the USA which are male.
  • The OR operator can be used in SQL to filter records that match at least one of multiple conditions.
  • The IN statement allows us to find the values that belong to a specified set, and is a shorthand for multiple OR statements.
  • The NOT IN operator allows us to return all rows not satisfying a given condition.
  • By combining the AND, OR, and NOT keywords through the use of parentheses, it is possible to create complex conditional logic in a single query.
  • The BETWEEN operator is used to filter out rows between two specified values (inclusive) from a table.