I have a dataset with variables empid and doj how to calculate retirement age?

Answer Posted / virat chary vadla

data joindates;
input empid$ doj date9.;
format doj is8601da.;
cards;
a101 01jan2000
a102 01aug2000
;

/*if retirement time is for 60 yrs then */


data ret_dates;
set joindates;
ret=intnx('year',doj,60,'same');
format ret doj is8601da.;
put 'for the empid--' empid 'retirement date is--' ret;
run;

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How might you use MOD and INT on numeric to mimic SUBSTR on character Strings?

747


How we can call macros with in data step? : sas-macro

609


What is SAS informats?

633


describe about metadata object? : Sas-di

621


what is the use of sas management console? : Sas-di

612






Name any two sas spawners? : sas-grid-administration

556


sas implementing companies in pune implementing clinical projects if anyone knows plz send ans immediately

3107


What are the parameters of scan function?

620


What is the maximum length of the macro variable? : sas-macro

617


what is sas application server, database server, sas olap server and sas metadata server? : Sas-di

551


Mention common programming errors committed in sas ?

645


in the flow of data step processing, what is the first action in a typical data step? : Sas programming

648


Difference between SAS STATA & SPSS?

676


what is a method for assigning first.var and last.var to the by groupvariable on unsorted data? : Sas programming

570


What is the order of application for output data set options, input data set options and SAS statements?

1080