Sort the EXPREV data set. PROC SORT sorts the observations by Sale_Type, Order_Date, and Quantity.


proc sort data=exprev;
   by sale_type order_date quantity;
run;