Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Needs to split one input file with diffrent LRECL

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
harithaganna

New User


Joined: 03 Jun 2008
Posts: 14
Location: chennai

PostPosted: Thu Jan 28, 2010 6:19 pm    Post subject: Needs to split one input file with diffrent LRECL
Reply with quote

Hi,

I have to split the one input file into two output files with diffrent LRECL e.g one output file with 250,and another with 170.

My Input file Layout:
Code:
SEQNO(10)
LENDER NO(6)
REPORTNO(3)
SSN(9)
BORROWER NAME(32)
LOAN TOKEN(11)
LOAN TYPE(3)
EFFECTIVE DATE(10)
AMOUNT1(10)
AMOUNT2(10)


My output file1 layout (170) My outfile2 Layout(260)
Code:
                                     SEQNOx(10)
SEQNOx(10)                     DESCRPTIONx(50)
FILENAMEx(10)                 FILENAMEx(10)
PORTFOLIOx(10)               PORTFOLIOx(10)
K1x(10)                            K1x(10)
K2x(10)                            K2x(10)
K3x(10)                            K3x(10) 
K4x(10)                            K4x(10) 
K5x(10)                            K5x(10)
K6x(10)                            K6x(10)
A1x(11)                            A1x(11)   
A2x(11)                            A2x(11)
A3x(11)                            A3x(11)
A4x(11)                            A4x(11)
A5x(11)                            A5x(11)
A6x(11)                             A6x(11)



We coded as
Code:
SORTIN     DD DSN=Inputfile
OUTDD1    DD DSN=OUTFILE1
                      DISP=(NEW,CATLG,CATLG),
                      UNIT=SYSDA,
                      SPACE=(TRK,(20,20),RLSE)
OUTDD2    DD DSN=OUTFILE2
                      DISP=(NEW,CATLG,CATLG),
                      UNIT=SYSDA,
                      SPACE=(TRK,(20,20),RLSE)
SYSIN DD *
      OPTION COPY
      OUTFIL FNAMES=OUTDD1,INCLUDE=(102,09,CH,EQ,113,09,CH),
                             OUTREC=(001:1,10,
                             011:C'ABCDEFGHIJ',
                             021:18,8,
                             031:11,6,
                             041:C'SPACES',
                             051:C'SPACES',
                             061:C'SPACES',
                             071:C'SPACES',
                             081:102,09,
                             093:C'0',
                            105:C'0',
                            117:C'0',
                            129:C'0',
                            141:C'0',
                           153:90,10)

              OUTFIL FNAMES=OUTDD2,INCLUDE=(102,09,CH,NE,113,09,CH),
                             OUTREC=(001:1,10,
                             011:C'ABCDEFGHIJ',
                             071:18,8,
                             081:11,6,
                             041:C'SPACES',
                             091:C'SPACES',
                             101:C'SPACES',
                             121:C'SPACES',
                             131:102,09,
                             143:C'0',
                            155:C'0',
                            167:C'0',
                             179:C'0',
                            191:C'0',
                          243:90,10)


When we give same length for outrec it will work fine.
When we give diffrent length in outrec it will not work.
Can you please tell me the solution.
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu Jan 28, 2010 6:56 pm    Post subject:
Reply with quote

We now know that it does not work, but unfortunately we do not know anything more.

In what way does it not work. Does the job abend, does the job fail to create output, does the job create output that you do not expect, or what .........

Please also post the output of the run that did not work as this may hold clues as to the reason.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Thu Jan 28, 2010 7:35 pm    Post subject: Reply to: Needs to split one input file with diffrent LRECL
Reply with quote

For OUTDD1, specifying:

153:90,10)

results in a total output record length of 162. If you want 170, then you should pad the records out:

153:90,10,170:X)

For OUTDD2, specifying:

243:90,10)

results in a total output record length of 252. If you want 250, then you'll have to trim something back. Specifying:

241:90,10)

would work.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Thu Jan 28, 2010 10:57 pm    Post subject:
Reply with quote

harithaganna,

When I use your control statements with DFSORT I get this error message:

ICE126A 9 INCONSISTENT OUTDD2 IFTHEN 0 REFORMATTING FIELD FOUND

This is the result of having overlapping fields in the OUTREC operand for OUTDD2. Specifically, you have:


Code:

...
   011:C'ABCDEFGHIJ',   
   071:18,8,           
   081:11,6,           
   041:C'SPACES',       
   091:C'SPACES',       
...


The next position after 81:11,6 is 87, but you have 41: so that's an overlap. If you want C'SPACES' at 41, you have to put them in their appropriate place:

Code:

...
   011:C'ABCDEFGHIJ',   
   041:C'SPACES',       
   071:18,8,           
   081:11,6,           
   091:C'SPACES',       
...


That will give you a return code 0, but as Kevin pointed out, OUTDD1 will have an LRECL of 162 instead of 170 and OUTDD2 will have an LRECL of 252 instead of 250, so you need to fix that as well.

I can't figure out from your description of your input and output fields what you really want, so I can't help you further unless you can clarify it.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts SSH - known_hosts file configuration vasanthz All Other Mainframe Topics 2 Wed Jul 26, 2017 2:10 am
This topic is locked: you cannot edit posts or make replies. Fetching data from BAI File arunsoods JCL & VSAM 1 Wed Jul 19, 2017 4:28 pm
No new posts Write out NODUPS but just from one file Jay Villaverde DFSORT/ICETOOL 8 Fri Jul 14, 2017 12:44 am
No new posts How to add header with Date(YYMMDD) i... Rajan Moorthy DFSORT/ICETOOL 2 Thu Jul 06, 2017 11:44 pm
No new posts How to generate a new unique Input fi... for1ranjith CLIST & REXX 11 Sat Jul 01, 2017 12:09 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us