Hello folks,
I have a SAS question. Please see the attached files. It is said that the answer is A but I want to believe that is is B, because program 3 needs a proc sort before it works. Any inputs?
Thanks and regards,
Thank you so much for your time and inputs. I did try to copy and paste the question into the window but it was not working. That's why I used the attachment. I believe running a fake data could also be helpful.
Regards,
Hi:
You did not say where you found the question. Was it in the Certification Prep Guide that we publish? If so, was it in the 4th edition or the 5th edition?
To make the data, so you can figure out the correct answer yourself, all you need is a DATA step program and the patience to make the datalines for input, as shown below:
data work.orders;
infile datalines dlm=',';
input Order_Date : mmddyy. Customer_ID $ Order_Total;
return;
datalines;
01/01/2011,B4523,52.30
01/02/2011,A2356,104.20
01/03/2011,C3467,27.40
01/04/2011,B4523,260.40
01/05/2011,A2356,74.54
;
run;
Then, once you have WORK.ORDERS, you can type and submit all 3 programs to see which ones work or don't work and why. If you are studying in the Certification Prep Guide, you should find a section that discusses using DATALINES as one method of creating a SAS table.
Cynthia
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.
Find more tutorials on the SAS Users YouTube channel.