Joined: 07 Jan 2003 Posts: 1056 Topics: 91 Location: The Blue Planet
Posted: Fri Sep 09, 2005 12:30 am Post subject:
mainframemouli,
I really wonder how you got "19,80" in your sysout while your job says "19,236".
I think there are two errors in your code.
1. You need to leave the First Column as Blank in your SYSIN card.
2. You cannot have 19,80 alone in one line and ")" in another line. They should be in the same line.
Try these things and if you still get an error, post your correct JCL & the error message.
Joined: 07 Jan 2003 Posts: 1056 Topics: 91 Location: The Blue Planet
Posted: Fri Sep 09, 2005 1:05 am Post subject:
Anil,
Positions are not a problem in this case. Col 13 + 6 Chars ends in Col 18, so by default 19,236 will start at Col 19 in the output also. If it really were a problem with positions then the error message would be "OUTREC HAS OVERLAPPING COLUMNS SPECIFIED"
As anil said i made the changes still it gives the error
Note : My Record LRECL is 80.
ICE143I 0 BLOCKSET COPY TECHNIQUE SELECTED
ICE000I 1 - CONTROL STATEMENTS FOR 5740-SM1, DFSORT REL 14.0 - 05:48 ON FRI SEP
SORT FIELDS=COPY
OUTREC FIELDS=(1:1,12,
13:13,6,CHANGE=(6,C'000000',C'BBBBBB'),
NOMATCH=(13,6),
19:19,80)
ICE201I 0 RECORD TYPE IS F - DATA STARTS IN POSITION 1
ICE027A 6 END OF FIELD BEYOND MAXIMUM RECORD LENGTH
ICE052I 3 END OF DFSORT
-------------------------------
And as phantom said the Jcl is exceuted still i am getting the error
ICE143I 0 BLOCKSET COPY TECHNIQUE SELECTED
ICE000I 1 - CONTROL STATEMENTS FOR 5740-SM1, DFSORT REL 14.0 - 05:46 ON FRI SEP
SORT FIELDS=COPY
OUTREC FIELDS=(1,12,
13,6,CHANGE=(6,C'BBBBBB',C'AAAAAA'),NOMATCH=(13,6),
19,80)
ICE201I 0 RECORD TYPE IS F - DATA STARTS IN POSITION 1
ICE027A 6 END OF FIELD BEYOND MAXIMUM RECORD LENGTH
ICE052I 3 END OF DFSORT
1,12 = copy first 12 bytes (So 80-12 = 68 bytes left to be copied )
your are changing the 6 bytes which starts from 13 (68-6 = 62 bytes left)
19,80 = you are trying to copy 80 bytes from pos 19 which makes the total lrecl to be 98 bytes, but your input file is only 80 bytes.
Joined: 26 Nov 2002 Posts: 12370 Topics: 75 Location: San Jose
Posted: Fri Sep 09, 2005 8:28 am Post subject:
Quote:
Suppose the same thing has to be done for VB file means what i have to do??
My VB LRECL is 850.
Mainframemouli,
For VB files you need to consider the RDW and then you code your actual data fields. The actual data starts from pos5 as the first 4 bytes will be occupied by RDW. With VB files you don't have to mention the length in OUTREC FIELDS = ( p , l )
for ex:
If you have a VB file of lrecl 100. you want to insert a constant('abc') in the first 3 bytes. you will code
Code:
SORT FIELDS=COPY
OUTREC FIELDS=(1,4, $ RDW
C'ABC', $ CONSTANT
5) $ ACTUAL DATA
If you notice , I did not mention the length portion on Actual data field as sort automatically will copy the record until the end for VB files
In your case lets assume that you want to perform similar processing as you did for your FB 80 byte file, the following control cards will give you the desired results.
1,4 = RDW
5,12 = copy the contents from pos5 for a length of 12 bytes
17,6,change = change the contents to bbbbbb when 000000 else copy the contents as is
23 = copy the contents from pos 23 till the end of the record
Joined: 02 Dec 2002 Posts: 1618 Topics: 31 Location: San Jose
Posted: Fri Sep 09, 2005 9:47 am Post subject:
mainframemouli,
Well, I see all of your questions were answered before I even got to work.
Since you seem to be unfamiliar with DFSORT syntax, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:
At that same link, you'll find "z/OS DFSORT Messages, Codes and Diagnosis Guide" where you can look up any DFSORT error message (ICExxxA) you get which may help you diagnose and fix errors yourself, and "z/OS DFSORT Application Programming Guide" which has the complete syntax for all of the DFSORT and ICETOOL statements and parameters.
Phantom wrote
Quote:
If it really were a problem with positions then the error message would be "OUTREC HAS OVERLAPPING COLUMNS SPECIFIED"
Actually, the DFSORT message for this situation would be:
ICE126A 2 INCONSISTENT *OUTREC IFTHEN 0 REFORMATTING FIELD FOUND _________________ 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