View previous topic :: View next topic
|
Author |
Message |
anandkumarrn
New User
Joined: 06 Feb 2009 Posts: 23 Location: India
|
|
|
|
Hi,
I am trying to Concatenate 3 datasets to one dataset using IEBGENER, But i am getting error as mentioned below,
My lrecl and Blksize are all same for all the 4 datasets, can some one suggest me what would be the problem is?
DATA SET UTILITY - GENERATE
IEB351I I/O ERROR ,HDRTLNDM,HDRTRL ,9BE0,D, ,READ ,NO RECORD FOUND,00001B2000006,BSAM |
|
Back to top |
|
|
MBabu
Active User
Joined: 03 Aug 2008 Posts: 400 Location: Mumbai
|
|
|
|
are you able to BROWSE (not Edit or View) the data sets and scroll all the way to the bottom? What is the JCL? |
|
Back to top |
|
|
anandkumarrn
New User
Joined: 06 Feb 2009 Posts: 23 Location: India
|
|
|
|
MBabu wrote: |
are you able to BROWSE (not Edit or View) the data sets and scroll all the way to the bottom? What is the JCL? |
Yes i can,
Code: |
//STEP01 EXEC PGM=IEBGENER
//SYSUT1 DD DSN=XXX,DISP=SHR
// DD DSN=YYY,DISP=SHR
// DD DSN=ZZZ,DISP=SHR
//SYSUT2 DD DSN=YYY,DISP=OLD
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSIN DD * |
Edited: Please use BBcode when You post some code/error, that's rather readable, Thanks... Anuj |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
Is file2 or file3 empty? Is there a proper end-of-file? Simply allocating the file may not be sufficient. . .
What happens if you run the process with one file at a time? |
|
Back to top |
|
|
MBabu
Active User
Joined: 03 Aug 2008 Posts: 400 Location: Mumbai
|
|
|
|
I tried this and it works with my test files. Are these files Fixed or Variable? I'm wondering if a variable record might have a zero length. I don't know how to create a file like that so I can't test the idea.
If this is a 1 time task, you can try ISPF option 3.3 (move/copy) and select MOD on the 2nd panel
btw, there is no SYSOUT DD for the utilities |
|
Back to top |
|
|
Bill Dennis
Active Member
Joined: 17 Aug 2007 Posts: 562 Location: Iowa, USA
|
|
|
|
Is DSN=YYY actually used as both INPUT and OUTPUT? |
|
Back to top |
|
|
anandkumarrn
New User
Joined: 06 Feb 2009 Posts: 23 Location: India
|
|
|
|
Bill Dennis wrote: |
Is DSN=YYY actually used as both INPUT and OUTPUT? |
Yes Dennis |
|
Back to top |
|
|
MBabu
Active User
Joined: 03 Aug 2008 Posts: 400 Location: Mumbai
|
|
|
|
Bill, your eyes are better than mine! Depending on the amount of data in XXX and blocksizes, I'd expect it to maybe get an x37 abend as it just copies data it has already written over and over, but if it reads past the nonexistent EOF of YYY this error would make sense. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
Bill Dennis wrote: |
Is DSN=YYY actually used as both INPUT and OUTPUT? |
Yes Dennis |
You have changed this so that the output dataset is no longer one of the inputs. . .? |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
|
|
|
|
If you really need to do this -- and most of the time it turns out not to be a requirement once looked at -- you will need to have a two-step job. The first step copies your three input files to a temporary file passed to the next step. The second step writes the temporary file back into the output file YYY as you called it.
In general, it is not a good idea to use the same file for input and output in one step unless you write the program to close the file between input and output operations -- for IEBGENER as the other utilities, you're not writing the program so you cannot control the processing. Therefore you should not use the same file for input and output for any utility.
Unpredictable results will occur when the same file is used for input and output at the same time -- often abends, sometimes corrupted data files. |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1248 Location: Richfield, MN, USA
|
|
|
|
Given the DISP of SYSUT2, I'm surprised the job ran at all. Wouldn't there have been an exclusive enque put on it to prevent the execution? |
|
Back to top |
|
|
MBabu
Active User
Joined: 03 Aug 2008 Posts: 400 Location: Mumbai
|
|
|
|
Terry Heinze wrote: |
Given the DISP of SYSUT2, I'm surprised the job ran at all. Wouldn't there have been an exclusive enque put on it to prevent the execution? |
not within the same address space. The whole job will get it as OLD. |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1248 Location: Richfield, MN, USA
|
|
|
|
My mistake. I think I was thinking the job consisted of 2 steps. I think in a 2 step job the DISP=OLD in step 2 would have prevented the 1st step from even starting wouldn't it? I can't test it since I have no access to a mainframe. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
|
|
|
|
In JES3, the DISP=OLD would force exclusive access to the data set for the entire job. |
|
Back to top |
|
|
|