The Orion.Employee_paryroll table is 5,0 Using SAS Functions Create a report tha
ID: 3802788 • Letter: T
Question
The Orion.Employee_paryroll table is5,0 Using SAS Functions Create a report that includes each employee's age at time of employment. a. report should contain the columns Employee ID, Birth Date, Employee Hire Date, and Age. b. obtain the data for the report from the orion.employee payroll table. c. Calculate Age as int ((Employee Hire Date-Birth Date) /365.25). d. Add this title to the report: Age at Employment. e. Display Birth Date and Employee Hire Date values using the MMDDYY 10. format. f Label each column as shown in the following sample report Partial PROC SQL Output Age at Employment Employee ID Birth Date Hire Date Age 120101 08/18/1980 07/01/2007 26 120102 08/11/1973 06/01/1993
Explanation / Answer
sample query:
- The report should have the fields are Employee_ID, Birth_date, Employee_Hire_Date and Age.
- There is no seperate field for age and it should be calculated as int((Employee_Hire_Date-Birth_date)/365.25) as Age
- Title should be TITLE 'Age at Employeement';
- And date will be displayed with MMDDYY10 format like Birth_date as Birth Date format=mmddyy10.,
TITLE 'Age at Employeement';
PROC SQL;
SELECT Employee_ID as Employee ID,
Birth_date as Birth Date format=mmddyy10.,
Employee_Hire_Date as Hire Date format=mmddyy10.,
int((Employee_Hire_Date-Birth_date)/365.25) as Age
FROM Employee_paryroll
QUIT;
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.