proc sql; title 'Employees with more than 30 Years of service as of December 31,2007'; select employee_name, intck('Year',employee_hire_date,'31dec2007'd) format=2. YOS as 'Year of Service', mgr (select employee_name from orion.employee_addresses where a.employee_id=employee_organization.manager_id) from orion.employee_addresses a ,orion.employee_payroll p where a.employee_id=p.employee_id having Year of Service >30 order by employee_name; quit; title; OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK; 72 73 proc sql; 74 title 'Employees with more than 30 Years of service as of December 31,2007'; 75 select employee_name, int('31dec2007'd-employee_hire_date/365.25) format=2. 76 YOS as 'Year of Service',mgr (select employee_name ___ _____________ 22 76 202 ERROR 22-322: Syntax error, expecting one of the following: a quoted string, ',', AS, FORMAT, FROM, INFORMAT, INTO, LABEL, LEN, LENGTH, TRANSCODE. ERROR 76-322: Syntax error, statement will be ignored. ERROR 202-322: The option or parameter is not recognized and will be ignored. 76 ! YOS as 'Year of Service',mgr (select employee_name _____________ 22 ERROR 22-322: Syntax error, expecting one of the following: !, !!, &, (, ), *, **, +, ',', -, '.', /, <, <=, <>, =, >, >=, ?, AND, BETWEEN, CONTAINS, EQ, EQT, GE, GET, GT, GTT, IN, IS, LE, LET, LIKE, LT, LTT, NE, NET, NOT, NOTIN, OR, ^, ^=, |, ||, ~, ~=. 77 from orion.employee_addresses 78 where a.employee_id=employee_organization.manager_id) 79 from orion.employee_addresses a ,orion.employee_payroll p 80 where a.employee_id=p.employee_id 81 having Year of Service >30 82 order by employee_name; NOTE: PROC SQL set option NOEXEC and will continue to check the syntax of statements. 83 quit; NOTE: The SAS System stopped processing this step because of errors. NOTE: PROCEDURE SQL used (Total process time): real time 0.00 seconds cpu time 0.01 seconds
... View more