Posted: Fri Feb 09, 2007 1:14 pm Post subject: merging two files to produce one output
Need help in producing a single report out of multiple. Receiving an error i do not understand. The control cards follows:
[code:1:c15f57746f]
* Split off 0400 and 0404 records and reformat
COPY FROM(IN) USING(CTL1)
* Keep only records that have the same userid in the 0400 record
* and the 0404 record
SELECT FROM(CONCT) TO(TEMP2) ON(1,44,CH) ALLDUPS
* Sort by profile fields from reformatted 0404 records
* with binary zeros in reformatted 0400 records.
SORT FROM(TEMP2) TO(TEMP1) USING(CTL2)
* Create report using needed fields from joined 0400 and 0404 records
DISPLAY FROM(TEMP1) LIST(PRNTDSP) BLANK -
TITLE(' data access records for hlq') -
BETWEEN(2) -
HEADER('profile namE') ON(1,44,CH) -
HEADER('authid') ON(46,8,CH) -
HEADER('access') ON(57,9,CH) -
HEADER('uacc') ON(68,8,CH) -
HEADER('grpid') ON(78,8,CH)
/*
//CTL1CNTL DD *
OUTFIL FNAMES=TEMP1,VTOF,
* Select 0400 records
INCLUDE=(5,4,CH,EQ,C'0400'),
* Reformat 0400 records to look like this:
*
Joined: 02 Dec 2002 Posts: 1618 Topics: 31 Location: San Jose
Posted: Fri Feb 09, 2007 2:38 pm Post subject:
Code:
OUTREC=(1:44,
46:8z,57:9z,68:133,8,78:156,8)
You have a column (1:), then a starting position (44) and then another column (46:). You need a starting postion and a length, not just a starting position. That is:
Code:
OUTREC=(1:p,m,
46:8Z,57:9Z,68:133,8,78:156,8)
p,m might be 1,44 or 44,10 or whatever you need. _________________ Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
frank,
i received the following errors:
[code:1:03f7a3c878]
CTL1CNTL :
OUTFIL FNAMES=TEMP1,VTOF,
* Select 0400 records
INCLUDE=(5,4,CH,EQ,C'0400'),
* Reformat 0400 records to look like this:
*
Joined: 02 Dec 2002 Posts: 1618 Topics: 31 Location: San Jose
Posted: Fri Feb 09, 2007 6:11 pm Post subject:
Pease show the error messages you received.
I don't see anything wrong with the first OUTREC operand (unless your input record is too small to contain the input fields you're trying to use), but it's hard to say without knowing the actual error message you received.
The second OUTREC operand has the same type of problem you had originally - 46:62,57: is missing the length - it should be 46:p,m,57: _________________ Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum