BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
zimcom
Pyrite | Level 9

 

Have

Randomization Date
2017-07-03
2017-07-04
2017-07-26
2018-06-07
2018-06-14
2018-06-17
2018-06-25
2018-06-28
2018-06-29
2019-07-09

 

Want 

Randomization DateNew Date
2017-07-032017-07-05
2017-07-042017-07-06
2017-07-262017-07-28
2018-06-072018-06-09
2018-06-142018-06-16
2018-06-172018-06-19
2018-06-252018-06-27
2018-06-282018-06-30
2018-06-292018-07-01
2019-07-092019-07-11
1 ACCEPTED SOLUTION

Accepted Solutions
PaigeMiller
Diamond | Level 26
new_date=randomization_date+2;

You can format new_date any way you want to make it readable.

--
Paige Miller

View solution in original post

3 REPLIES 3
PaigeMiller
Diamond | Level 26

Am I correct in understanding that you want to add two days to Randomization_Date?

 

Could you please tell us if Randomization_Date is a valid SAS date value which is a numeric variable, or is it a character string?

--
Paige Miller
zimcom
Pyrite | Level 9

Yes, adding 2 days. and Randomization_Date is a valid SAS numeric date value.  

PaigeMiller
Diamond | Level 26
new_date=randomization_date+2;

You can format new_date any way you want to make it readable.

--
Paige Miller

Ready to join fellow brilliant minds for the SAS Hackathon?

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!
How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 458 views
  • 0 likes
  • 2 in conversation