Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Syncsort to find day of the week

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Aneesh

New User


Joined: 30 Sep 2006
Posts: 60

PostPosted: Wed Nov 19, 2008 5:54 pm    Post subject: Syncsort to find day of the week
Reply with quote

Hi,

I need to create a file that has the day of the week - Sun, Mon, Tue etc or a number indicator for the day 1 for Sunday, 2 for Mon etc.

Can this be done using syncsort?

Thanks,
Aneesh.
Back to top
View user's profile Send private message

Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2284
Location: @my desk

PostPosted: Wed Nov 19, 2008 6:57 pm    Post subject:
Reply with quote

Aneesh,

Do you have an input file for this. It's not clear what you're trying to achieve. Please post a few sample input/output records.
Back to top
View user's profile Send private message
Aneesh

New User


Joined: 30 Sep 2006
Posts: 60

PostPosted: Wed Nov 19, 2008 11:07 pm    Post subject: Reply to: Syncsort to find day of the week
Reply with quote

Hi,

Basically i need to have some processing in the jcl that is different for differnt days of the week. For that, i need to create a new file (FB LRECL 80) which has the current day of the week.

Is there any option like &DATE1 which would give the day of the week or any easy way to determine the current day of the week to write to a file.

Thanks,
Aneesh.
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2284
Location: @my desk

PostPosted: Wed Nov 19, 2008 11:25 pm    Post subject:
Reply with quote

Aneesh,

Is it fine to have a number ranging from 1 to 7 in a file. Every time the file will have a number corresponding to the day of the week. Say '1' for Sun, '2' for Mon etc. If yes, you can easily do it in sort without any date function. But after having this in a file, how do you plan to process your jcl differently?
Back to top
View user's profile Send private message
Aneesh

New User


Joined: 30 Sep 2006
Posts: 60

PostPosted: Thu Nov 20, 2008 9:49 pm    Post subject: Reply to: Syncsort to find day of the week
Reply with quote

Hi,

Yes. It woul dbe fine to write a number representing the day of the week.

I am planning to write this to a file only when the value meets a prticular day's value. The output file should be empty on the other days. The jcl processign would be controlled by an empty file check. We are not doing this through CA7 as this day is likely to be changed in the future.

Thanks,
Aneesh.
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2284
Location: @my desk

PostPosted: Thu Nov 20, 2008 11:24 pm    Post subject:
Reply with quote

Aneesh,

Is this going to be a daily job?
Quote:

I am planning to write this to a file only when the value meets a prticular day's value. The output file should be empty on the other days. The jcl processign would be controlled by an empty file check. We are not doing this through CA7 as this day is likely to be changed in the future.

I dint get this.
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2284
Location: @my desk

PostPosted: Thu Nov 20, 2008 11:33 pm    Post subject:
Reply with quote

Aneesh,

If you mean to find the day of the week from a random date, I dont think it's possible using any of the DATE functions in sort unless you use some exit routines.
Back to top
View user's profile Send private message
Aneesh

New User


Joined: 30 Sep 2006
Posts: 60

PostPosted: Fri Nov 21, 2008 12:25 am    Post subject: Reply to: Syncsort to find day of the week
Reply with quote

Hi Arun,

I need the day of the week of the current date - sorry for the confusion.

Thanks,
Aneesh.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts find RACF group for access to spooled... jzhardy JCL & VSAM 1 Mon May 08, 2017 11:46 am
No new posts To find out size allocated to a seque... ashek15 JCL & VSAM 15 Thu Apr 27, 2017 9:42 am
No new posts SYNCSORT SEQNUM and FI fields. nartcr SYNCSORT 7 Sat Jan 21, 2017 4:02 am
No new posts Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts find particular member name in PDS us... ravi243 CLIST & REXX 10 Mon Dec 19, 2016 6:44 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us