View previous topic :: View next topic |
Author |
Message |
infoman123 Beginner
Joined: 02 Nov 2004 Posts: 57 Topics: 20
|
Posted: Fri Dec 10, 2004 8:26 am Post subject: OPC...adding a new dependancy on dataset |
|
|
All,
We are using OPC as our job scheduler in our shop.In that i have job depending on another 2 jobs.I want add one more dependecy as below.
In my job,i use a dataset which is coming from an external party.Some times they dont transmit this or send this late.Because of that my job abends.I wanted to give the dependecy on this datset also.Is this possible??
Can any one help me in this... |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12375 Topics: 75 Location: San Jose
|
Posted: Fri Dec 10, 2004 8:39 am Post subject: |
|
|
Infoman123,
I don't know much about OPC but can't your trigger your job whenever you receive the dataset from the external source. change the triggering of the job to kick off whenever the dataset is sent.
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
|
infoman123 Beginner
Joined: 02 Nov 2004 Posts: 57 Topics: 20
|
Posted: Fri Dec 10, 2004 9:52 am Post subject: |
|
|
Kolusu,
I would like to know,how to trigger it automatically when datasent is sent without any manual intervention.
The only way i know to check whther a dataset is present or not is thru Rexx but unfortunately I cannot execute any rexx routine in production.
Could you suggest any other methods. |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12375 Topics: 75 Location: San Jose
|
Posted: Fri Dec 10, 2004 10:07 am Post subject: |
|
|
infoman123,
As I mentioned earlier, I haven't worked on OPC , Our shop has CA-7 Schedueling package and it allows a job to be triggered by dataset. I hope OPC has also a similar feature.
If you cannot find one then here is another simple alternative is to create an empty gen before your actual pgm that reads the file.
Let us say you receive the file from an external source. You store it on the mainframe as a GDG
Code: |
HLQ.ABC.TRANS.FILE <== gdg base
|
A new gen is created everytime you receive a file from the external source.
Code: |
HLQ.ABC.TRANS.FILE.GnnnnV00
|
Now add a step that reads this empty file.
Code: |
//FIRSTSTEP EXEC PGM=IEFBR14
//*
//FILE01 DD DSN=HLQ.ABC.TRANS.FILE(+1),
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(TRK,(1,1),RLSE),
// DCB=(MODEL,RECFM=FB,LRECL=ZZZ,BLKSIZE=0)
//*
//NEXTSTEP EXEC PGM=MYPGM
//SYSOUT DD SYSOUT=*
//INPUT DD DSN=HLQ.ABC.TRANS.FILE,
// DISP=(OLD,DELETE,KEEP)
...
|
Note that we give the GDG base as input for your pgm and after successful completion of the pgm we delete all the generations of the file using DISP parameter.
Every time the job gets triggered we will create an empty gen of your file and thereby avoid the abends.
Hope this helps...
Cheers
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
|
infoman123 Beginner
Joined: 02 Nov 2004 Posts: 57 Topics: 20
|
Posted: Fri Dec 10, 2004 11:11 am Post subject: |
|
|
Kolusu,
actually,if the file is not transmitted,i should not process my job with this empty file.It has to wait until the file is transmitted.
I hope i dint confuse yoy.
regards |
|
Back to top |
|
|
|
|