On 9/22/2010 11:38 AM, Frank Yaeger wrote:
Frank Swarbrick on IBM Mainframe Discussion List<[email protected]>
wrote on 09/22/2010 10:23:28 AM:
Does DFSORT conversion from a "day of the year" format to an actual
date format? Specifically, we have a file that stores dates as
packed-decimal 5 characters (+ sign), ie YYDDDs where YY is the two
digit year, DDD is the day of the year and s is the sign nibble. I
am able to use "p,m,Y2U,EDIT=(TTTT/TTT)" to convert to display
"YYYY/DDD" format but what I really want is "YYYY/MM/DD" or "DD/MM/
YYYY" format.
Frank,
You can use DFSORT's date conversion functions to do that:
p,3,Y2U,TOGREG=(Y4T(/))
will give you a 'yyyy/mm/dd' date.
Frank, I was going to suggest that, but the DFSORT
doc seems to imply that's not allowed:
z/OS 1.12 DFSORT Application Programming Guide (PDF version)
table 47 on page 289 seems to indicate that for a Y2U
input, that TOGREG= is not an allowed conversion; am I
reading the table incorrectly, or is there an error in
the doc?
1,3,Y2U,DT=(DM4/)
will give you a 'dd/mm/yyyy' date.
For complete details on DFSORT's date conversion functions, see:
http://www.ibm.com/support/docview.wss?rs=114&uid=isg3T7000174
Frank Yaeger - DFSORT Development Team (IBM) - [email protected]
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
--
Kind regards,
-Steve Comstock
The Trainer's Friend, Inc.
303-393-8716
http://www.trainersfriend.com
* To get a good Return on your Investment, first make an investment!
+ Training your people is an excellent investment
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html