Hello, I am trying to calculate an age variable.
The input format of brth_date (birth date) and scrn_date (screening date) is datetime 22.3.
the output format is numeric best12.
I am receiving the error: "Invalid character data" (Log below)
Any help would be appreciated.
Thank you!!
brth_date = datepart (brthdat); if recorddate > . then scrn_date = datepart (recorddate); else scrn_date = datepart (icdat); age = floor(yrdif (brth_date, scrn_date,'age'));
Could you please check if you have the age already derived in DM1 dataset.
Could you please check if you have the age already derived in DM1 dataset.
Wow, so when I initialized the variables in the dm1 data set, I accidentally set age = ' ' instead of age = .
Thank you!
Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.
Register today!Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Select SAS Training centers are offering in-person courses. View upcoming courses for: