View previous topic :: View next topic
|
Author |
Message |
cpuhawg
Active User
Joined: 14 Jun 2006 Posts: 331 Location: Jacksonville, FL
|
|
|
|
I have over 300,000 fixed blocked 48 byte records. The date is in positions 39-48 in YYYY-MM-DD format. I need to read these records into ICETOOL and separate them into two output datasets:
1. Records 90 days and older based on current date.
2. Records 89 days and younger based on current date.
There are also records on the input dataset that have no date (blanks in positions 39-48). I want these records directed to the "Records 90 days and older based on current date" output dataset.
Here are some sample input records:
Code: |
----+----1----+----2----+----3----+----4----+---
CICS123 ABC07 VXX PORT 07 - QB7X 2008-08-01
CICS123 ABC08 VXX PORT 08 - QB7Y 2008-08-08
CICS123 ABC09 VXX PORT 09 - QB7Z 2008-07-14
CICS123 ABC10 VXX PORT 10 - QB70
CICS123 ABC11 VXX PORT 11 - QB74 2008-08-11
CICS123 ABC12 VXX PORT 12 - QB75 2008-04-15
CICS123 ABC13 VXX PORT 13 - QB76 2005-03-11
CICS123 ABC14 VXX PORT 14 - QB77 2008-07-24
CICS123 ABC15 VXX PORT 15 - QB78
CICS123 ABC16 VXX PORT 16 - QB79 2008-03-01
CICS123 ABC17 VXX PORT 17 - QB8A 2008-01-13
CICS123 ABC18 VXX PORT 18 - QB8B 2008-06-13
CICS123 ABC19 VXX PORT 19 - QB80
CICS123 ABC20 VXX PORT 20 - QB81 2008-08-09
CICS123 ABC21 VXX PORT 21 - QC6Q 2007-05-29
CICS123 ABC22 VXX PORT 22 - QC6R 2007-08-11
CICS123 ABC23 VXX PORT 23 - QC6S 2008-05-11
|
Thank you. |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Here's a DFSORT/ICETOOL job that will do what you asked for:
Code: |
//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN DD DSN=... input file
//GT90 DD DSN=... output file1
//LE90 DD DSN=... output file2
//TOOLIN DD *
COPY FROM(IN) USING(CTL1)
/*
//CTL1CNTL DD *
OUTFIL FNAMES=GT90,
INCLUDE=(39,10,CH,EQ,C' ',OR,39,10,CH,LE,DATE1(-)-90)
OUTFIL FNAMES=LE90,SAVE
/*
|
|
|
Back to top |
|
|
cpuhawg
Active User
Joined: 14 Jun 2006 Posts: 331 Location: Jacksonville, FL
|
|
|
|
Thanks for the solution. It looks pretty straight forward from the control cards.
I also needed the records summed up (counted), but prior examples you have provided using the REMOVECC, NODETAIL, SECTIONS=(, and TRAILER3=( parameters has allowed me to understand the logic behind counting records based on a key field.
ICETOOL is an outstanding product!!
Have a great day. |
|
Back to top |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Quote: |
ICETOOL is an outstanding product!! |
I'm glad you like DFSORT's ICETOOL. |
|
Back to top |
|
|
|