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
 

 

ToConvert the below date format using DFSORT

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
nvsnaidu

New User


Joined: 09 Nov 2007
Posts: 7
Location: Chennai

PostPosted: Fri Nov 09, 2007 2:11 pm    Post subject: ToConvert the below date format using DFSORT
Reply with quote

How to convert a source date of say 2007310 i.e CCYYJULIANDATE to target date CYYMMDD and target date should occupy 4 bytes
Back to top
View user's profile Send private message

murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1439
Location: Bangalore,India

PostPosted: Fri Nov 09, 2007 3:11 pm    Post subject:
Reply with quote

Venkat,

This was discussed earlier. Go thru the link-

http://ibmmainframes.com/about7034.html
Back to top
View user's profile Send private message
nvsnaidu

New User


Joined: 09 Nov 2007
Posts: 7
Location: Chennai

PostPosted: Fri Nov 09, 2007 4:30 pm    Post subject: Reply to: ToConvert the below date format using DFSORT
Reply with quote

Thanks a lot murmohk1
Back to top
View user's profile Send private message
nvsnaidu

New User


Joined: 09 Nov 2007
Posts: 7
Location: Chennai

PostPosted: Sat Nov 10, 2007 1:53 pm    Post subject: Reply to: ToConvert the below date format using DFSORT
Reply with quote

My date is of type 9(07) i.e '2007310' . so i converted that date first to PD
date of lenght 4 and then got the required output date of format PD and lenght 4 i.e 0071109

The below is the sort card.

Code:

  OPTION COPY                                                         
  INREC IFTHEN=(WHEN=INIT,                                           
       BUILD=(1,7,ZD,TO=PD,LENGTH=4)),                               
     IFTHEN=(WHEN=INIT,                                           
       BUILD=(1:1,1,CHANGE=(1,X'19',X'00',X'20',X'01'),             
         NOMATCH=(X'02'),2:2,3))                                       
  OUTREC FIELDS=(1,4,DT1,TO=PD,LENGTH=4)                             


Thanks a lot to Frank Yaeger & Murmohk1
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1439
Location: Bangalore,India

PostPosted: Sat Nov 10, 2007 2:06 pm    Post subject:
Reply with quote

Venkat,

You are welcome.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Fri Nov 20, 2009 11:29 pm    Post subject:
Reply with quote

With z/OS DFSORT V1R5 PTF UK51706 or z/OS DFSORT V1R10 PTF UK51707 (Nov, 2009), DFSORT now has built-in date conversion functions. For complete details on date conversion functions and the other new functions available with the Nov, 2009 DFSORT PTF, see:

http://www.ibm.com/support/docview.wss?rs=114&uid=isg3T7000174
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts How to pick only YYMMDD from DATE1P (... atulbaviskar SYNCSORT 7 Wed Mar 22, 2017 11:39 am
No new posts Date and time format in CICS Chandru3183 CICS 2 Sat Mar 18, 2017 12:46 pm
No new posts How to get current date -1 and curren... murali.andaluri DFSORT/ICETOOL 3 Wed Mar 08, 2017 2:09 pm
No new posts DFSORT MUL FIELDS tspr52 DFSORT/ICETOOL 16 Fri Mar 03, 2017 11:53 pm
No new posts Overlay the system date Danielle.Filteau SYNCSORT 4 Fri Mar 03, 2017 1:16 am


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