Chapter Contents |
Previous |
Next |
The COMPARE Procedure |
Main discussion: | BY |
BY
<DESCENDING> variable-1
<...<DESCENDING> variable-n> <NOTSORTED>; |
Required Arguments |
Options |
The requirement for ordering observations according to the values of BY variables is suspended for BY-group processing when you use the NOTSORTED option. The procedure defines a BY group as a set of contiguous observations that have the same values for all BY variables. If observations with the same values for the BY variables are not contiguous, the procedure treats each contiguous set as a separate BY group.
BY Processing with PROC COMPARE |
Condition | Behavior of PROC COMPARE | |
---|---|---|
All BY variables are in the comparison data set and all attributes match exactly | Compares corresponding BY groups | |
None of the BY variables are in the comparison data set | Compares each BY group in the base data set with the entire comparison data set | |
Some BY variables are not in the comparison data set | Writes an error message to the SAS log and terminates | |
Some BY variables have different types in the two data sets | Writes an error message to the SAS log and terminates |
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.