|
View previous topic :: View next topic
|
| Author |
Message |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
Hi,
I am using the below mentioned PROC:
| Code: |
//STEP04 EXEC PGM=ISRSUPC,
// PARM=(DELTAL,LINECMP,
// '',
// '')
//NEWDD DD DSN=ABC.IN1.D110817,
// DISP=SHR
//*
//OLDDD DD DSN=ABC.IN1.D110816,
// DISP=SHR
//*
//OUTDD DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(1,1),RLSE),
// DISP=(MOD,PASS),
// DCB=(RECFM=FB,LRECL=255)
//*
// IF (STEP04.RC EQ 1) THEN
//STEP05 EXEC PGM=SORT
//*
//SORTIN DD DSN=&&T1,DCB=(RECFM=FB,LRECL=255),
// DISP=MOD
//*
//SORTOUT DD DSN=ABC.IN1.D110817.COMPARE,
// DISP=(NEW,CATLG,DELETE),UNIT=RESDA,
// DCB=*.SORTIN,SPACE=(CYL,(1000,2000),RLSE)
//*
//SORTWK01 DD UNIT=SYSDA
//SORTWK02 DD UNIT=SYSDA
//*
//SYSIN DD *
SORT FIELDS=COPY
INCLUDE COND=(2,3,CH,EQ,C'I -',OR,2,3,CH,EQ,C'D -')
/*
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
// ENDIF
|
The Issue that I am facing is that when there is a difference in the files, then the return code of 1 is set. However at this instance the job is not executing STEP05 i.e. the SORT Step. I have tried to use COND as well as IF statement.
| Code: |
-PROCNAME STEPNAME PROGRAM RC EXCP
-STEP04 CCCCC ISRSUPC 01 140
-STEP05 CCCCC SORT FLUSH 0
|
Can anyone point out where exactly I m going wrong?
[/code] |
|
| Back to top |
|
 |
superk
Global Moderator

Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
| I don't understand. You says it's a PROC, yet you have a statement that uses a DD* for instream data, which is not allowed in a PROC. |
|
| Back to top |
|
 |
vasanthz
Global Moderator

Joined: 28 Aug 2007 Posts: 1750 Location: Tirupur, India
|
|
|
|
Hello,
How come you have //SYSIN DD *
on a proc
Edited: Contention with SuperK |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
| Thats because I have just copied the PARM into the SYSIN DD * statement to provide the complete JCL |
|
| Back to top |
|
 |
dbzTHEdinosauer
Global Moderator

Joined: 20 Oct 2006 Posts: 6965 Location: porcelain throne
|
|
|
|
well, I did not know that you could have instream data in a PROC
superk was a little faster,
so I will add an addendum to my post.
yet another Topic Starter who is attempting to BS us. |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
The thing that I would like to know is how can I execute STEP05 when I have difference in the files that are referred in sTEP04.
If there is a difference, then return code of '01' is set and STEP05 is getting FLUSHED. |
|
| Back to top |
|
 |
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
| swapnadeep.ganguly wrote: |
| Thats because I have just copied the PARM into the SYSIN DD * statement to provide the complete JCL |
So next time, tell us when you do something like that please. So far everyone has been thinking "is this a PROC, or not, it can't be" - so much wasted time. |
|
| Back to top |
|
 |
dbzTHEdinosauer
Global Moderator

Joined: 20 Oct 2006 Posts: 6965 Location: porcelain throne
|
|
|
|
| Code: |
-PROCNAME STEPNAME PROGRAM RC EXCP
-STEP04 CCCCC ISRSUPC 01 140
-STEP05 CCCCC SORT FLUSH 0 |
don't where you are copying or 'creating' the above
but
the proc and stepname are assbackwards.
since you tend to edit posts and provide us with useless information
(WTF do we want to know the sort control statements)
would not be surprised if you are looking at the wrong job. |
|
| Back to top |
|
 |
dbzTHEdinosauer
Global Moderator

Joined: 20 Oct 2006 Posts: 6965 Location: porcelain throne
|
|
|
|
what is important is to cut&paste the output of the JESJCL,
and the JESYSMSG.
you have only provided us with your interpretation of the job
and the summary.
you want answers, give us detail. |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
My sincere apologies to everyone due to the error that I had posted.
Hope I have made myself clear on the aspect where I am getting the unwanted response. |
|
| Back to top |
|
 |
vasanthz
Global Moderator

Joined: 28 Aug 2007 Posts: 1750 Location: Tirupur, India
|
|
|
|
Tested & works fine,
| Code: |
//TEST PROC
//SUPERC EXEC PGM=ISRSUPC,
// PARM=(DELTAL,LINECMP,
// '',
// '')
//NEWDD DD DSN=WELLS.SORTOUT,
// DISP=SHR
//OLDDD DD DSN=WELLS.SORTIN,
// DISP=SHR
//OUTDD DD SYSOUT=(A)
// IF (SUPERC.RC EQ 1) THEN
//JS020 EXEC PGM=IEFBR14
// ENDIF
//TEST PEND |
| Code: |
JOBNAME STEPNAME PROCSTEP RC
TESTER JS010 SUPERC 01
TESTER JS010 JS020 00 |
:S |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
JESYSMSG:
| Code: |
IEF142I TXXX1930 STEP04 XXX1930C - STEP WAS EXECUTED - COND CODE 0001
IGD104I HLQ.DL.XXX1950.UPDATE.IN1.D110817 RETAINED, DDNAME=NEWDD
IGD104I HLQ.DL.XXX1950.UPDATE.IN1.D110816 RETAINED, DDNAME=OLDDD
IGD106I SYS11228.T112816.RA000.TXXX1930.T1.H02 PASSED, DDNAME=OUTDD
IGD104I HLQ.XXX.PRODPARM RETAINED, DDNAME=SYSIN
********************************************************************************
* DDNAME UNIT EXCPS BLKSIZE * DDNAME UNIT EXCPS BLKSIZE * DDNAME
* NEWDD D-CF4A 48 27795 * OLDDD D-CF37 48 27795 * OUTDD
* SYSIN D-CF49 4 3120 * *
********************************************************************************
* TCB TIME: .02 PAGING I/O COUNTS: 0 DISK I/O COUNTS: 101 P
* SRB TIME: .00 SWAPS I/O COUNTS: 0 TAPE I/O COUNTS: 0 U
* PERF GROUP: 0 ADDR. SPACE SWAPS: 0 VIRT I/O COUNTS: 0 U
********************************************************************************
IEF373I STEP/STEP04 /START 2011228.1128
IEF374I STEP/STEP04 /STOP 2011228.1128 CPU 0MIN 00.02SEC SRB 0MIN 00.00S
IEF202I TXXX1930 STEP05 XXX1930C - STEP WAS NOT RUN BECAUSE OF CONDITION CODES
IEF272I TXXX1930 STEP05 XXX1930C - STEP WAS NOT EXECUTED.
|
JESJCL:
| Code: |
IEFC653I SUBSTITUTION JCL - SYSOUT=*
XXSTEP04 EXEC PGM=ISRSUPC,
XX PARM=(DELTAL,LINECMP,
XX 'NOPRTCC',
XX '')
XXNEWDD DD DSN=&HLQ..DL.XXX1950.UPDATE.IN&FNUM..D&YYMMDD,
XX DISP=SHR
XX*
IEFC653I SUBSTITUTION JCL - DSN=HLQ.DL.XXX1950.UPDATE.IN1.D110817,DISP=SHR
XXOLDDD DD DSN=&HLQ..DL.XXX1950.UPDATE.IN&FNUM..D&PREVDT,
XX DISP=SHR
XX*
IEFC653I SUBSTITUTION JCL - DSN=HLQ.DL.XXX1950.UPDATE.IN1.D110816,DISP=SHR
XXOUTDD DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(1,1),RLSE),
XX DISP=(MOD,PASS),
XX DCB=(RECFM=FB,LRECL=255)
XX*
XXSYSIN DD DSN=&VLM..&PARMLIB(XXX19306),DISP=SHR
XX*
XX IF (STEP04.RC EQ 1) THEN
XXSTEP05 EXEC PGM=SORT
XX*
XXSORTIN DD DSN=&&T1,DCB=(RECFM=FB,LRECL=255),
XX DISP=MOD
XX*
XXSORTOUT DD DSN=&HLQ..DL.XXX1950.UPDATE.IN&FNUM..COMPARE1,
XX DISP=(NEW,CATLG,DELETE),UNIT=RESDA,
XX DCB=*.SORTIN,SPACE=(CYL,(1000,2000),RLSE)
XX*
IEFC653I SUBSTITUTION JCL - DSN=HLQ.DL.XXX1950.UPDATE.IN1.COMPARE1,DISP=(NEW,CATLG,DELETE),
DCB=*.SORTIN,SPACE=(CYL,(1000,2000),RLSE)
XXSORTWK01 DD UNIT=SYSDA
XXSORTWK02 DD UNIT=SYSDA
XXSYSIN DD DSN=&VLM..&PARMLIB(XXX19305),
XX DISP=SHR
XX*
IEFC653I SUBSTITUTION JCL - DSN=HLQ.XXX.PRODPARM(XXX19305),DISP=SHR
XXSYSOUT DD SYSOUT=*
XXSYSPRINT DD SYSOUT=*
XX ENDIF
|
|
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
The Surprising thing is:
When I used IEFBR14 as done by Vasanth, it executed fine:
| Code: |
//SUPERC EXEC PGM=ISRSUPC,
// PARM=(DELTAL,LINECMP,
// '',
// '')
//NEWDD DD DSN=IN1.D110817,
// DISP=SHR
//OLDDD DD DSN=IN1.D110816,
// DISP=SHR
//OUTDD DD SYSOUT=(A)
// IF (SUPERC.RC EQ 1) THEN
//JS020 EXEC PGM=IEFBR14
// ENDIF
|
JESYSMSG:
| Code: |
IEF142I TMVD1930 SUPERC - STEP WAS EXECUTED - COND CODE 0001
IGD104I @SWAP.DL.MVD1950.UPDATE.IN1.D110817 RETAINED, DDNAME=NEWDD
IGD104I @SWAP.DL.MVD1950.UPDATE.IN1.D110816 RETAINED, DDNAME=OLDDD
IEF285I @SWAP.TMVD1930.JOB03533.D0000101.? SYSOUT
********************************************************************************
* DDNAME UNIT EXCPS BLKSIZE * DDNAME UNIT EXCPS BLKSIZE * DDNAME
* NEWDD D-CF3F 48 27795 * OLDDD D-CF37 48 27795 * OUTDD
********************************************************************************
* TCB TIME: .01 PAGING I/O COUNTS: 0 DISK I/O COUNTS: 96 P
* SRB TIME: .00 SWAPS I/O COUNTS: 0 TAPE I/O COUNTS: 0 U
* PERF GROUP: 0 ADDR. SPACE SWAPS: 0 VIRT I/O COUNTS: 0 U
********************************************************************************
IEF373I STEP/SUPERC /START 2011228.1201
IEF374I STEP/SUPERC /STOP 2011228.1201 CPU 0MIN 00.01SEC SRB 0MIN 00.00S
IEF142I TMVD1930 JS020 - STEP WAS EXECUTED - COND CODE 0000
|
However, when the same is not executing successfully with PGM=SORT.
I am really surprised with this... |
|
| Back to top |
|
 |
Garry Carroll
Senior Member
Joined: 08 May 2006 Posts: 1216 Location: Dublin, Ireland
|
|
|
|
Your snippets from the jobs look incomplete. Are there steps before
| Code: |
| XXSTEP04 EXEC PGM=ISRSUPC, |
Garry. |
|
| Back to top |
|
 |
vasanthz
Global Moderator

Joined: 28 Aug 2007 Posts: 1750 Location: Tirupur, India
|
|
|
|
Hello,
Just a guess,
Does the JCL have COND=(0,NE) on the statement which refers the PROC?
Something like,
//JS010 EXEC TEST,COND=(0,NE)
This would cause,
| Code: |
STEPNAME PROCSTEP RC
JS010 SUPERC 01
JS010 JS020 FLUSH |
|
|
| Back to top |
|
 |
Marso
REXX Moderator

Joined: 13 Mar 2006 Posts: 1356 Location: Israel
|
|
|
|
As Garry suggested, check the steps before.
Certainly there is another step named STEP04. |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
| Quote: |
Does the JCL have COND=(0,NE) on the statement which refers the PROC?
|
No Vasanth,
There is no COND code as you had mentioned.
| Quote: |
Your snippets from the jobs look incomplete. Are there steps before
|
Yes there are STEPS before which are simply FTP'ing files from the server for the current date and then its comparing with the file from the previous date. |
|
| Back to top |
|
 |
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
| So can you list the stepname cards for the earlier steps? |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
The Step name cards are as mentioned below:
| Code: |
//STEP01 EXEC PGM=IEFBR14
//*
//STEP02 EXEC PGM=IRXJCL,
// PARM='ABCDEFGH +$=1/$PDATE=&YYMMDD/$HLQ=&HLQ/$FNUM=&FNUM'
//*
:
:
//STEP03 EXEC PGM=FTP,REGION=7M,
// PARM='&IPARM1&IPARM2&IPARM3'
//*
:
:
//STEP04 EXEC PGM=ISRSUPC,
// PARM=(DELTAL,LINECMP,
// 'NOPRTCC',
// '')
:
:
// IF (STEP04.RC EQ 1) THEN
//STEP05 EXEC PGM=SORT
//*
:
:
// ENDIF
|
|
|
| Back to top |
|
 |
Garry Carroll
Senior Member
Joined: 08 May 2006 Posts: 1216 Location: Dublin, Ireland
|
|
|
|
So far, all we are getting is edited snippets - we don't know what's being edited out. We really need to see the ENTIRE job - from the JOBCARD through any procs/steps up to the point of failure. Otherwise , it's a bit like performing surgery wearing a blindfold.
Garry. |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
The complete job are as under:
Proc:
| Code: |
//STEP01 EXEC PGM=IEFBR14
//*
//DD01 DD DSN=&HLQ..&FREQ..&RUNPARM..D&YYMMDD,
// DISP=(MOD,DELETE,DELETE),
// UNIT=&UNIT,
// SPACE=(TRK,&SPACE,RLSE)
//*
//DD02 DD DSN=&HLQ..DL.MVD1950.UPDATE.IN&FNUM..COMPARE,
// DISP=(MOD,DELETE,DELETE),
// UNIT=&UNIT,
// SPACE=(TRK,&SPACE,RLSE)
//*
//DD03 DD DSN=&HLQ..DL.MVD1950.UPDATE.IN&FNUM..COMPARE1,
// DISP=(MOD,DELETE,DELETE),
// UNIT=&UNIT,
// SPACE=(TRK,&SPACE,RLSE)
//*
//STEP02 EXEC PGM=IRXJCL,
// PARM='ABCDEFG +$=1/$PDATE=&YYMMDD/$HLQ=&HLQ/$FNUM=&FNUM'
//*
//SYSEXEC DD DSN=REXX.LIBRARY,
// DISP=SHR
//*
//TXTIN DD DSN=&PARMLIB(XXXX1111),
// DISP=SHR
//*
//TXTOUT DD DSN=&HLQ..&FREQ..&RUNPARM..D&YYMMDD,
// DISP=(NEW,CATLG,DELETE),
// UNIT=&UNIT,
// SPACE=(TRK,&SPACE,RLSE),
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=0)
//*
//SYSTSPRT DD SYSOUT=&SYSOUTX
//SYSPRINT DD SYSOUT=&SYSOUTX
//SYSOUT DD SYSOUT=&SYSOUTX
//*
//STEP03 EXEC PGM=FTP,REGION=7M,
// PARM='&IPARM1&IPARM2&IPARM3'
//*
//INPUT DD DSN=&HLQ..&FREQ..&RUNPARM..D&YYMMDD,
// DISP=SHR
//*
//SYSPRINT DD SYSOUT=&SYSOUTX
//SYSOUT DD SYSOUT=&SYSOUTX
//*
//STEP04 EXEC PGM=ISRSUPC,
// PARM=(DELTAL,LINECMP,
// 'NOPRTCC',
// '')
//NEWDD DD DSN=&HLQ..DL.MVD1950.UPDATE.IN&FNUM..D&YYMMDD,
// DISP=SHR
//*
//OLDDD DD DSN=&HLQ..DL.MVD1950.UPDATE.IN&FNUM..D&PREVDT,
// DISP=SHR
//*
//OUTDD DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(1,1),RLSE),
// DISP=(MOD,PASS),
// DCB=(RECFM=FB,LRECL=255)
//*
// IF (STEP04.RC EQ 1) THEN
//STEP05 EXEC PGM=SORT
//*
//SORTIN DD DSN=&&T1,DCB=(RECFM=FB,LRECL=255),
// DISP=MOD
//*
//SORTOUT DD DSN=&HLQ..DL.MVD1950.UPDATE.IN&FNUM..COMPARE1,
// DISP=(NEW,CATLG,DELETE),UNIT=RESDA,
// DCB=*.SORTIN,SPACE=(CYL,(1000,2000),RLSE)
//*
//SORTWK01 DD UNIT=SYSDA
//SORTWK02 DD UNIT=SYSDA
//SYSIN DD DSN=&PARMLIB(YYYY2222),
// DISP=SHR
//*
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
// ENDIF
|
Job Card:
| Code: |
//AAAABBBB JOB (0415,MV00),'PROD CNTL OCE',
// CLASS=A,
// NOTIFY=&SYSUID,
// MSGCLASS=X,
// REGION=8M
//*
//PROCS JCLLIB ORDER=(PRODPROC.LIBRARY)
//*
//**********************************************************
//* THIS STEP DELETES THE FOLLOWING FILES (EXISTING FILES)
//* OR THE NEW ONE GETTING CREATED DURING RUN IF IT IS NON E
//**********************************************************
//MVD1930A EXEC MVRDLET,
// FILE01='&HLQ..DL.MVD1950.UPDATE.IN&FNUM..D&YYMMDD'
//*
//MVD1930B EXEC MVFTPA,
// FNUM='1',
// YYMMDD='110817',
// PREVDT='110816',
// IPARM2='(EXIT=01 ',
// COND=(0,NE)
|
|
|
| Back to top |
|
 |
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
I don't suppose the "other" proc has a cunningly-name STEP04 has it?
You don't have much space in a stepname, but you can make them more meaningful. If they are going to be meaningless, why not SNNN and save on all the rest of the typing? |
|
| Back to top |
|
 |
swapnadeep.ganguly
Active User

Joined: 21 Mar 2007 Posts: 203 Location: India
|
|
|
|
| No, there is no other PROC as you had mentioned. |
|
| Back to top |
|
 |
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
| swapnadeep.ganguly wrote: |
| No, there is no other PROC as you had mentioned. |
Really? I'm confused then. I can see
| Quote: |
| //MVD1930A EXEC MVRDLET |
and
| Quote: |
| //MVD1930B EXEC MVFTPA |
Which is the one that does not exist?
If I have to spell it out, if MVRDLET has a step cunningly-named STEP04, then you will be testing that RC for your IF and I suspect it would be zero so the equally cunningly-named STEP05 in the second PROC would not run. |
|
| Back to top |
|
 |
dbzTHEdinosauer
Global Moderator

Joined: 20 Oct 2006 Posts: 6965 Location: porcelain throne
|
|
|
|
and again, another
"I have provided all the info necessary, now solve my problem" |
|
| Back to top |
|
 |
|
|
 |
All times are GMT + 6 Hours |
|