The WHERE clause criteria specifies criteria for selecting record occurrences based on field values of a named database record, logical record, or ASF table.
Access mode: The syntax below is invalid when the access switch is set to IDMS.
This selection criteria is an expansion of the:
Syntax:
►►─┬─┬───────┬─┬─ comparison-expression ──┬───────────────────────────────────► │ └─ NOT ─┘ └─ dba-designated-keyword ─┘ │ │ └─┬─ EXIsts ─────┬─ (subquery) ──────────────────────────────────────────── └─ NOT exists ─┘ ►─┬──────────────────────────────────────────────────────┬─┬─────────────────►◄ │ ┌──────────────────────────────────────────────────┐ │ │ └─▼─┬─ AND ─┬─┬───────┬─┬─ comparison-expression ──┬─┴─┘ │ └─ OR ──┘ └─ NOT ─┘ └─ dba-designated-keyword ─┘ │ ──────────────────────────────────────────────────────────┘
Syntax rules:
Specifies a comparison operation to be performed using the named operands and operator.
Note: Complete syntax rules for comparison-expression are discussed later in this chapter.
Specifies a logical record keyword that is predefined by the DBA. DBA-designated-keyword is a keyword that applies to the logical record named in the command. The keyword represents an operation to be performed at the logical record path level and serves only to route the logical record request to the appropriate path; it has no meaning to CA OLQ.
When a SHOW LOGICAL RECORDS command is issued, CA OLQ lists the keywords associated with each logical record defined in the current subschema.
Note: This parameter is used in the WHERE clause only.
Evaluates the outcome of subquery in terms of whether it is true (EXISTS) or false (NOT EXISTS).
Subquery is a nested SELECT statement. The SELECT statement must be enclosed in parentheses. The column list of SELECT statements containing the EXISTS or NOT EXISTS operands must be an asterisk (*), specifying all columns. The subselect statement cannot contain:
Note: This parameter is used in the WHERE clause only.
Names the logical operators to be used in evaluating the WHERE clause.
Table 1 lists the logical operators and their meanings in order of precedence. NOT has the highest precedence, followed by AND, then OR. Parentheses can be used to force the order of evaluation.
Table 1: Logical Operators
|
Operator |
Example |
Meaning |
|---|---|---|
|
NOT |
NOT comparison |
If comparison is false, expression is true. |
|
AND |
Comparison A AND comparison B |
If comparison A and comparison B are both true, expression is true. |
|
OR |
Comparison A OR comparison B |
If either comparison A or comparison B is true, expression is true. |
|
Copyright © 2013 CA.
All rights reserved.
|
|