MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problem with VBS type file

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Job Control Language(JCL)
View previous topic :: View next topic  
Author Message
Chaitanya
Beginner


Joined: 11 Jul 2004
Posts: 3
Topics: 2

PostPosted: Mon Aug 09, 2004 2:37 pm    Post subject: Problem with VBS type file Reply with quote

Hi All,

My main aim is to add few characters to the VSAM file which is of VB format ( i think VBS). So, I copied this into a file and whenever I am trying to sort this file and add few characters while creating a new file, it is abending with a return code of 16.

This is happening only when I am accessing the logical record length more than the Avg. Record Size. i.e if I am giving my outfile record length more than the average one ( average and max. are not equal), though there are few records more than avg length, its abending.

One of the reasons might be that its trying to access more than the record length for few records.

So please help me out in finding a way to do this step.

Thanks in Advance,
Chaitanya
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Aug 09, 2004 2:51 pm    Post subject: Reply with quote

Chaitanya,

can you post the job you are trying to run? And also the error messages from your sysout.

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Chaitanya
Beginner


Joined: 11 Jul 2004
Posts: 3
Topics: 2

PostPosted: Fri Aug 20, 2004 8:28 am    Post subject: Reply with quote

Hi,

Thank you for the response, and sorry for not looking into this since these many days.

I am afraid that I dont have a copy of sysout AND the jcl too, im trying to reproduce the jcl hrere, its abending the moment it encounters the sort statement.

The avg record length of input VSAM is 82, key location is 10.
Code:

//FILEIN   DD DSN=VSAM.ABC.DEF,DISP=SHR
//FILEOUT  DD DSN=SEQ.ABC.DEF.BKUP,
//           DISP=(NEW,CATLG,DELETE),
//            SPACE=(CYL,(100,25),RLSE),
//            DCB=(RECFM=VB,LRECL=1272,BLKSIZE=)
//SYSOUT   DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSABEND DD SYSOUT=*
//SYSIN    DD *
 here we copied directly from in to out.

Now, we used
Code:

//FILEIN   DD DSN=SEQ.ABC.DEF.BKUP,DISP=SHR
//FILEOUT  DD DSN=SEQ.ABC.DEF.NEW,
//            DISP=(NEW,CATLG,DELETE),
//            SPACE=(CYL,(100,25),RLSE),
//            DCB=(RECFM=VB,LRECL=1282,BLKSIZE=)
//SYSOUT   DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSABEND DD SYSOUT=*
//SYSIN    DD *
 SORT FIELDS=COPY
 OUTREC FIELDS=(1:1,80,10X,91:81,1192)
/*
//*

The problem was not regarding the total size of the file, but rather whenever it started copying the 83rd field, it abended. We came to this conclusion as we were decreasing the output length and checking.

This is how it went. However, we have now solved it with the help of a small program. But please inform me, if there is any utililty for doing this type of things thorugh jcl only.

We also tried with DFSORT which has something like VLFILL, which helps in converting VB to fixed by adding low or high values. But i dont know whether we can do the reverse, bcos we finally need the VSAM file only to be increased by length.

Please help me out with a utility.

Thanks and Regards,
Chaitanya.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Fri Aug 20, 2004 9:09 am    Post subject: Reply with quote

Chaitanya.

First of all your JCL has many errors.

1.You don't have SORTIN or a SORTOUT.
2.If you wanted to convert a variable block file to a fixed block file then you CONVERT parm which is missing in your sort cards.

Try this Job.

Code:

//STEP0100 EXEC PGM=SORT
//SYSOUT   DD SYSOUT=*
//SORTIN   DD DSN=SEQ.ABC.DEF.BKUP,
//            DISP=SHR
//SORTOUT  DD DSN=SEQ.ABC.DEF.NEW,
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,
//            SPACE=(CYL,(100,25),RLSE)
//SYSIN    DD *
   SORT FIELDS=COPY
   OUTREC FIELDS=(1,80,10X,81)
/*


I am guessing that this job will run fine, If it doesn't then paste the contents of the sysout.

Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
MikeBaker
Beginner


Joined: 04 May 2004
Posts: 96
Topics: 9

PostPosted: Mon Aug 23, 2004 7:11 am    Post subject: Reply with quote

Another great utility which can add stuff to a file (and juggle around the field arrangement) is ICEGENER. See below:
Code:

//STEP020  EXEC PGM=ICEGENER,COND=(4,LT)
//SYSPRINT DD SYSOUT=*
//SYSUT1   DD DISP=SHR,DSN=SNQ267.BBM.AABB.GREEK.CARDS
//SYSUT2   DD DISP=SHR,DSN=SNQ267.BBM.AABB.GREEK.EXCEL
//*length, old file position, new file position)
//SYSIN    DD *
  GENERATE MAXFLDS=40,MAXLITS=40
  RECORD FIELD=(19,01,,001),
               FIELD=(01,';',,020),
               FIELD=(9,'         ',,29)

Heres what happens...
1: For a length of 19, data from pos. 1 in Input, is moved to pos.1 in Output
2: For a length of 1, at pos. 20 in Output, the semi-colon is placed.
3: For a length of 9, at pos. 29 in the Output, nine Spaces are inserted.

Also, you seem slightly uncertain about the characteristics of your VSAM file (ie: VB or maybe VBS). So... to save some thinking, when you are allocating an Output file which has the same DCB characteristics as the Input, instead on your Output DCB, code "DCB=*.SORTIN". It makes things so much easier.
Back to top
View user's profile Send private message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Mon Aug 23, 2004 11:38 am    Post subject: Reply with quote

Mike,

FYI, your job actually uses IEBGENER, not ICEGENER. ICEGENER is DFSORT's replacement for IEBGENER. ICEGENER uses DFSORT copy unless it can't in which case it uses IEBGENER. In your case, since you're supplying IEBGENER control statements, DFSORT copy can't be used and ICEGENER uses IEBGENER.

However, IEBGENER cannot process VSAM files whereas DFSORT/ICEGENER can.
Note that you can use DFSORT control statements in DFSPARM with ICEGENER to do what you're doing with IEBGENER.
_________________
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
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Job Control Language(JCL) All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
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


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group