override a specific SYSIN in PROC from a JCL



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

Re: override a specific SYSIN in PROC from a JCL

Postby dn2012 » Fri Apr 20, 2012 12:09 am

It's work but I have noticed following message in the output file

IGD17101I DATA SET TSSDN.DATA.COPY3 421
NOT DEFINED BECAUSE DUPLICATE NAME EXISTS IN CATALOG
RETURN CODE IS 8 REASON CODE IS 38 IGG0CLEH
dn2012
 
Posts: 114
Joined: Thu Feb 16, 2012 6:10 am
Has thanked: 0 time
Been thanked: 0 time

Re: Re: override a specific SYSIN in PROC from a JCL

 

Re: override a specific SYSIN in PROC from a JCL

Postby dn2012 » Fri Apr 20, 2012 12:17 am

I removed SYSIN DD DUMMY from the proc (as every one said earlier) and its work fine.
I will try to use substitute varibale in step 2 also.
dn2012
 
Posts: 114
Joined: Thu Feb 16, 2012 6:10 am
Has thanked: 0 time
Been thanked: 0 time

Re: override a specific SYSIN in PROC from a JCL

Postby BillyBoyo » Fri Apr 20, 2012 12:22 am

OK, first thing to recognise is that it didn't work.

You probably got a non-zero return-code with this, as well.

This is one of those times when the answer is obvious without looking up the message.

Either by accident or without you realising it, you have previously run the step successfully and cataloged your dataset (note, this has nothing to do with cataloged procedures, just because the word is the same).

To get the step to run correctly, you have to delete that dataset.

First step though, is to say "my step didn't work". Say it ten times. It is something you need to get used to, it'll happen many, many times. When you do something wrong, even by accident, it is you who did it - not the computer, operating system or anyone else. If you don't accept that up front, you'll find it much harder to fix your mistakes.

I believe I have mentioned this to you before. You really have to take it to heart. It is not a criticism. It is not for some enjoyment of mine. I had to go failures when I started as well. I've said it in the hope that you will learn something, and get better at what you are doing.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 264 times

Re: override a specific SYSIN in PROC from a JCL

Postby BillyBoyo » Fri Apr 20, 2012 12:26 am

dn2012 wrote:I removed SYSIN DD DUMMY from the proc (as every one said earlier) and its work fine.
I will try to use substitute varibale in step 2 also.


I'm not aware that anyone mentioned DD DUMMY being any sort of a problem in a PROC. Is the above a typo? Did you mean DD *?

Now, you might want to use the substitution in step2, but you won't be able to as you are trying to substitute in a "card", which won't work. Remember, they were physical things. Couldn't change 'em. Until z/OS 1.13.

To do the symbol substitution in data you'll need to use another program. I seem to remember that your site has DFSORT. Try searching the DFSORT part of the forum for JPn or JP1 and tell us what you think.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 264 times

Re: override a specific SYSIN in PROC from a JCL

Postby NicC » Fri Apr 20, 2012 1:44 am

If you mean you removed the SYSIN DD * and associated 'cards' then of course it worked because those 'cards' tell the program called IDCAMS what to do. No cards - no work (except, perhaps, to complain about no work to do).
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2690
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 105 times

Re: override a specific SYSIN in PROC from a JCL

Postby dn2012 » Fri Apr 20, 2012 2:18 am

Substitute variable also work for me.

//EXTPROC PROC                                                     
//STEP1        EXEC PGM=IEFBR14                                     
//SQADB512 DD  DSN=&DSNAME,DISP=(NEW,CATLG,DELETE),                 
//             SPACE=(TRK,(5,3,1)),UNIT=SYSDA,                     
//             DCB=(RECFM=FB,LRECL=80,BLKSIZE=800,DSORG=PO)         
//STEP2    EXEC PGM=IEBCOPY                                         
//SYSPRINT DD SYSOUT=*                                             
//SYSUT1   DD DISP=SHR,DSN=&SRCTPE   <= INPUT TAPE                 
//SYSUT2   DD DISP=(NEW,CATLG),UNIT=TAPE,DSN=TSSDN.DATA.COPY3       
//*SYSIN    DD DUMMY                                                 
//STEP3    EXEC PGM=IDCAMS,REGION=512K                               
//SYSPRINT DD SYSOUT=*                                               
//*SYSIN    DD DUMMY                                                 
//         PEND                                                       
//FINAL EXEC EXTPROC,DSNAME=TSSDN.DEMO.TEMP02,SRCTPE=TSSDN.DATA.COPY2
//STEP2.SYSIN DD *                                                   
//STEP3.SYSIN DD *                                                   
    DEFINE GDG( -                                                     
    NAME(TSSDN.GDBD.TEMP02)-                                         
    LIMIT(7) NOEMPTY SCRATCH)                                         
/*                                                                   
//   



OUTPUT from SYSPRINT:

PDF0103C DEFAULT COPY OUTDD=SYSUT2,INDD=SYSUT1 * GENERATED
PDF0111I REUNLOAD: SYSUT1 DSN=TSSDN.DATA.COPY2 VOL=535682(TAPE)
PDF0113I UNLOAD DATASET'S PHYSIC
PDF0112I SYSUT2 DSN=TSSDN.DATA.COPY3 VOL=874400(TAPE)

IDCAMS SYSTEM SERVICES

DEFINE GDG( -
NAME(TSSDN.GDBD.TEMP02)-
LIMIT(7) NOEMPTY SCRATCH)
IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 0

IDC0002I IDCAMS PROCESSING COMPLETE. MAXIMUM CONDITION CODE WAS 0

thanks
dn2012
 
Posts: 114
Joined: Thu Feb 16, 2012 6:10 am
Has thanked: 0 time
Been thanked: 0 time

Re: override a specific SYSIN in PROC from a JCL

Postby BillyBoyo » Fri Apr 20, 2012 3:28 am

Well, JCL substitutions would work. The one that wouldn't, in the data cards, you've finally removed.

If you are happy with that, we're happy. If you want to paramerise the control cards for IDCAMS, DFSORT can generate them.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 264 times

Previous

Return to JCL

 


  • Related topics
    Replies
    Views
    Last post