View previous topic :: View next topic
|
Author |
Message |
arunsoods
New User
Joined: 13 Jul 2016 Posts: 35 Location: India
|
|
|
|
Hi Team,
I required to read a data set from another data set for which I donot have any idea how can I achieve please let me know if it is possible or not.
Code: |
G7D208MM G7UBB.ACCT.DD.FILE.IN(0) 08
G7D207MM G7UBB.HIERCHY.DD.FILE.IN(0) 08
G7D403MM G7UBB.PRDP.LOANPERF.FILE.IN(0) 08
G7D200MM G7UBB.LB.MGT.FILE.IN(0) 16 |
In above file I have jobName(G7208MM) FileName(G7UBB.ACCT.DD.FILE.IN(0)) and location(08) from where I want to pick the sequence number. The sequence number is of 4 byte & is at trailer of the file & at above mentioned byte location. |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
You need 2 jobs - the first to read your data set containg data set names, select the data set required and generate the second job to process that data set.
Or, with the programming language of your choice, do it in one step using dynamic allocation. |
|
Back to top |
|
|
arunsoods
New User
Joined: 13 Jul 2016 Posts: 35 Location: India
|
|
|
|
Thanks Nic do we need to generate a job for each data set..?
Do you have any sample code that do the similar task..? |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
Quote: |
do we need to generate a job for each data set |
Without knowing your full requirements how would anyone know?
Quote: |
Do you have any sample code that do the similar task..? |
Plenty of examples around on this, and other forums. |
|
Back to top |
|
|
sergeyken
Senior Member
Joined: 29 Apr 2008 Posts: 2010 Location: USA
|
|
|
|
arunsoods wrote: |
I required to read a data set from another data set for which I donot have any idea how can I achieve |
Hum-m-m...
Does anyone have an idea about reading a dataset from another dataset??? |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8696 Location: Dubuque, Iowa, USA
|
|
|
|
Quote: |
Do you have any sample code that do the similar task..? |
This is a forum for experts -- as in people who can either use the Internet to find what they need or know how to write code without needing sample code. Asking for code on this forum, you should be prepared to pay professional rates for the code -- $500 to $2000 per day of coding are typical rates here. Perhaps you would be better off on Beginners and Students Forum instead of this forum? The code to use BPXWDYN for dynamic allocation has been posted multiple times and is pretty straightforward code. It is maybe 100 lines of COBOL (depending upon how complex you want to get), and less in other languages.
Furthermore, what will you do once you've found the sequence number? Use it in a program? Use it as a JCL parameter? Write it to another data set? |
|
Back to top |
|
|
|