132 proc sort data=Patients out=SORTED_PATIENTS;
133 by descending admitdate;
NOTE: There were 4 observations read from the data set WORK.PATIENTS.
NOTE: The data set WORK.SORTED_PATIENTS has 4 observations and 2 variables.
NOTE: PROCEDURE SORT used (Total process time):
real time 0.02 seconds
cpu time 0.01 seconds
The sort procedure orders the observations of a dataset by the values of one or more character or numeric variables. The statement, by descending admitdate; is used so the dataset will be sorted based on the values of admitdate in descending order. The following dataset is generated:
The one and only FREE resource for general SAS online training as well as study guides for the SAS Base Certification. My goal is to create the SAS Certification prep guide that I never found but always wanted. This should also be a place to come if you are new to the language but are simply looking for online SAS training.