Defining Search Conditions
Now that you have an idea of how to create a simple WHERE clause, let’s take a closer look at the five basic types of predicates you can define.
Comparison
The most common type of condition is one that uses a comparison predicate to compare two value expressions to each other. As you can see in Figure 6-2, you can define six different types of comparisons using the following comparison predicate operators.
Figure 6-2. The syntax diagram for the comparison condition
= Equals<> Not Equal To< Less Than> Greater Than<= Less Than or Equal To>= Greater Than or Equal To
Comparing String Values: A Caution
You can easily ...
Get SQL Queries for Mere Mortals: A Hands-On Guide to Data Manipulation in SQL, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.