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

Julian Date format as YYYDDD


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
yianis

New User


Joined: 14 Aug 2006
Posts: 45

PostPosted: Mon Sep 17, 2007 9:15 pm
Reply with quote

I looked before I posted and tried several things, but I want to know if this can be done in one single step...
Code:

  OPTION COPY,STOPAFT=1                                   
  OUTREC BUILD=(C'MYDATE,''',DATE3,C'''',80:X)           


the output is
Code:
MYDATE,'2007260'


I do not want the first number as I want the output to be

Code:
MYDATE,'007260'


Is there a format for that?

I know I can massage the data in a further step, but wondering if I can do that in the same step with some format?
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


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

PostPosted: Mon Sep 17, 2007 9:50 pm
Reply with quote

You can do it in one pass with these DFSORT statements:

Code:

  OPTION COPY,STOPAFT=1                   
  INREC BUILD=(C'MYDATE,''',DATE3,C'''')   
  OUTREC BUILD=(1,8,10,7,80:X)             


or these DFSORT statements:

Code:

  OPTION COPY,STOPAFT=1                   
  INREC IFOUTLEN=80,                     
   IFTHEN=(WHEN=INIT,                     
     BUILD=(C'MYDATE,''',DATE3,C'''')),   
   IFTHEN=(WHEN=INIT,                     
     BUILD=(1,8,10,7))                   
Back to top
View user's profile Send private message
yianis

New User


Joined: 14 Aug 2006
Posts: 45

PostPosted: Mon Sep 17, 2007 10:28 pm
Reply with quote

Hi Frank,

I should have thought of that myself...I feel silly!

Thanks as always !!!!
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 -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Populate last day of the Month in MMD... SYNCSORT 2
No new posts Modifying Date Format Using DFSORT DFSORT/ICETOOL 9
No new posts Need to convert date format DFSORT/ICETOOL 20
No new posts Need help to append a date&tsp at... DFSORT/ICETOOL 9
No new posts InfoSphere OPTIM CSV ouput vs DSNTIUA... IBM Tools 3
Search our Forums:

Back to Top