DATA Step, Macro, Functions and more

Date Formats

Reply
Frequent Contributor
Posts: 140

Date Formats

Hi, does anyone have a list of Date formats at all please?

 

As an example I have %let date=201606 so I will have yymmn6. but I don't have any others.

 

Many Thanks

Steve

PROC Star
Posts: 547

Re: Date Formats

Frequent Contributor
Posts: 140

Re: Date Formats

Thank you

Super User
Super User
Posts: 7,392

Re: Date Formats

Do note, there were formats added for version 9, ISO ones for instance.  You would be better looking at a later version's webpage:

http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a001263753.htm

 

For the OP: Putting dates in macro variables is never a good idea.  You may think that text string is a date format, it is not, it is purely text.  Any opertaion on it would need bth conversion, and checking to to make sure its correct, 3 times the effort, no benefit.

Frequent Contributor
Posts: 140

Re: Date Formats

Thanks RW9!

Super Contributor
Posts: 394

Re: Date Formats

Here are links to the online SAS 9.4 doc for formats by category, and for informats by category.

Ask a Question
Discussion stats
  • 5 replies
  • 244 views
  • 0 likes
  • 4 in conversation