|
|
| Author |
Message |
jaspal
New User
Joined: 22 May 2007 Posts: 42 Location: mumbai
|
|
|
|
We have one file , in which we have to append the current date during run time.
we can do this using the DATE1 fuction in sort
| Code: |
SORT FIELDS=COPY
OUTREC FIELDS=(DATE1,1,10)
|
but the date appended is in yyyymmdd format.
Any idea how do can we get it in ddmmccyy format?
regards,
Jaspal |
|
| Back to top |
|
 |
References
|
Posted: Sat Apr 05, 2008 11:24 am Post subject: Re: Appending the current date during run time. |
 |
|
|
 |
dick scherrer
Global Moderator
Joined: 23 Nov 2006 Posts: 6883 Location: 221 B Baker St
|
|
| Back to top |
|
 |
Frank Yaeger
DFSORT Moderator
Joined: 15 Feb 2005 Posts: 3952 Location: San Jose, CA
|
|
|
|
Jaspal,
Assuming that you want the ddmmyyyy date followed by bytes 1-10 of the input record, you would use these DFSORT statements:
| Code: |
SORT FIELDS=COPY
OUTREC BUILD=(1:DATENS=(DM4),1,10)
|
Note: The syntax you showed was incorrect. I corrected it. |
|
| Back to top |
|
 |
patypaz
New User
Joined: 21 Jun 2007 Posts: 2 Location: Brazil
|
|
|
|
Thank you!
Great work!!!! |
|
| Back to top |
|
 |
|
|