A predicate is specified in a
WHERE condition in a statement which is "true", "false", or "unknown". The result is generated by applying the predicate to a specific row in a result table (see result table name) or to a group of rows in a table that was formed by the GROUP clause.Syntax
<predicate> ::=
<between_predicate> | <bool_predicate> | <comparison_predicate>
| <default_predicate> | <exists_predicate> | <in_predicate>
| <join_predicate> | <like_predicate> | <null_predicate>
| <quantified_predicate> | <rowno_predicate> | <sounds_predicate>
Explanation
Model table:
Selection without a condition:
SELECT city, name, firstname FROM customer
CITY |
NAME |
FIRSTNAME |
New York |
Porter |
Jenny |
Dallas |
DATASOFT |
? |
Los Angeles |
Porter |
Martin |
Los Angeles |
Peters |
Sally |
Hollywood |
Brown |
Peter |
New York |
Porter |
Michael |
New York |
Howe |
George |
Los Angeles |
Randolph |
Frank |
Los Angeles |
Peters |
Joseph |
Los Angeles |
Brown |
Susan |
Los Angeles |
Jackson |
Anthony |
Los Angeles |
Adams |
Thomas |
New York |
Griffith |
Mark |
Los Angeles |
TOOLware |
? |
Hollywood |
Brown |
Rose |
Selection with restricting condition:
SELECT city, name, firstname FROM customer
WHERE city = 'Los Angeles'
CITY |
NAME |
FIRSTNAME |
Los Angeles |
Porter |
Martin |
Los Angeles |
Peters |
Sally |
Los Angeles |
Peters |
Joseph |
Los Angeles |
Brown |
Susan |
Los Angeles |
Jackson |
Anthony |
Los Angeles |
Adams |
Thomas |
Los Angeles |
TOOLware |
? |