The following guidelines help you determine when to use a WHERE clause in SAS
and
when to use a SYSTEM 2000
where-clause to specify selection criteria.
Use a SYSTEM 2000 where-clause in your
view descriptor when you want to do one of the following actions:
-
restrict users of
view descriptors to specific subsets of data.
-
use SYSTEM 2000
syntax and functionality, such as
component names, stored strings, HAS, AT, and the NON-KEY specification.
-
qualify using a
database item that is not in the view descriptor.
-
ensure that nulls (missing values)
are treated how SYSTEM 2000 expects. (The SYSTEM 2000 handling of
nulls differs from SAS in that SYSTEM 2000 does not treat nulls as
equal to other values, including other nulls.)
-
use the SYSTEM 2000 functionality
of the NOT operator. (The SYSTEM 2000 processing of the NOT operator
differs from SAS in that SYSTEM 2000 includes null values in the answer,
where SAS might or might not include nulls.)
-
prevent users from sequentially passing the entire database. (The DBA can also set
the SYSTEM 2000 option to DISABLE FULL PASSES as a way of
preventing sequential processing.)
Use a WHERE clause
in SAS when the preceding guidelines do not apply, and you have one
of the following situations:
-
you need more run-time flexibility
in subsetting data
-
you need to use WHERE clause capabilities
in SAS that SYSTEM 2000 does not support, such as arithmetic expressions
or truncated comparisons