SAS_Institute
A00-201 · Question #51
The contents of the SAS data set PERM.JAN_SALES are listed below: VARIABLE NAME TYPE idnum character variable sales_date numeric date value A comma delimited raw data file needs to be created from…
The correct answer is B. libname perm 'SAS-data-library'; data _null_; set perm.jan_sales; file 'file-specification' dlm = ''; put idnum sales_date : mmddyy10.; run. See the full explanation below for the reasoning.
Question
The contents of the SAS data set PERM.JAN_SALES are listed below: VARIABLE NAME TYPE idnum character variable sales_date numeric date value A comma delimited raw data file needs to be created from the PERM.JAN_SALES data set. The SALES_DATE values need to be in a MMDDYY10 form. Which one of the following SAS DATA steps correctly creates this raw data file?
Options
- Alibname perm 'SAS-data-library'; data null; set perm.jan_sales; file 'file-specification' dsd = ''; put idnum sales_date : mmddyy10.; run;
- Blibname perm 'SAS-data-library'; data null; set perm.jan_sales; file 'file-specification' dlm = ''; put idnum sales_date : mmddyy10.; run;
- Clibname perm 'SAS-data-library'; data null; set perm.jan_sales; file 'file-specification'; put idnum sales_date : mmddyy10. dlm = ''; run;
- Dlibname perm 'SAS-data-library'; data null; set perm.jan_sales; file 'file-specification'; put idnum sales_date : mmddyy10. dsd = ''; put idnum sales_date : mmddyy10. dsd = ''; run;
How the community answered
(20 responses)- A5% (1)
- B80% (16)
- C10% (2)
- D5% (1)
Community Discussion
No community discussion yet for this question.