IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to pass a current date in a SAS step in JCL


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Fri Feb 06, 2009 6:48 am
Reply with quote

Hi,

How to pass the current date in a SAS step of a JCL so that the email that is being generated by the SAS step picks that up.

Thanks a many for the help....
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Fri Feb 06, 2009 7:57 am
Reply with quote

SAS has the TODAY() function which returns the current date ... why would you need to pass it from JCL?
Back to top
View user's profile Send private message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Fri Feb 06, 2009 8:04 am
Reply with quote

Wow... but I'm a layman to SAS, I just know few basic commands... So it would be more helpful if you could throw some light on this...
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Fri Feb 06, 2009 8:11 am
Reply with quote

Code:
CD = TODAY () ;
FORMAT CD YYMMDDN8. ;
creates variable CD to have the current date and formats it as YYMMDD for output.

Use [URL] BBCode for External Links has a link to the SAS documentation and there's a link to all their documentation (Support & Training at the top, then Product Documentation under Knowledge Base on the left) which is available without charge. I recommend you do some reading there since SAS is a very complex, full-featured programming language with over 35 years of history.
Back to top
View user's profile Send private message
VVRAVINDRA

New User


Joined: 04 Aug 2008
Posts: 46
Location: Chennai

PostPosted: Fri Feb 06, 2009 8:12 am
Reply with quote

Thanks a many for the help I would give a try to it.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Modifying Date Format Using DFSORT DFSORT/ICETOOL 9
No new posts To get the the current time DFSORT/ICETOOL 13
No new posts Need to convert date format DFSORT/ICETOOL 20
No new posts Return codes-Normal & Abnormal te... JCL & VSAM 7
No new posts Changeman - how can we know the curr... Compuware & Other Tools 2
Search our Forums:

Back to Top