View previous topic :: View next topic
|
Author |
Message |
sandeep kumar302
New User
Joined: 14 Mar 2012 Posts: 81 Location: India
|
|
|
|
Hi,
I am new to Mainframe technology and i have requirement like below:
1. I have a flat file which contains the job details with the expanded PROC with dataset name.
2. The datasets has so many JCLS in expanded order.
3. My requirement is to capture all the job names and the datasets associated with the job names.
4. I am planning to use string and unstring concept but not sure how to proceed the coding. Can someone please help?
I am pasting the details of the files below:
//ABCDEFGH JOB .....................MSGCLASS=X,CLASS=
..
...
...
..
..EXEC PROC
...
..
//-- DSN=a.b.c,Disp=shr
..
..
Please note that the position of //Jobname i.e //ABCDEFGH here is not in a particular position and can vary
i want to apply logic like-
a) Read the lines one by one
b) If a line contains the keyword (MSGCLASS or CLASS) or has the keyword JOB then after the "//" symbol it should be job name and i have to capture the job name here ABCDEFGH
c) then i have to capture all the datasets associated to this job name until the next job name comes.
d) please note that to capture the datasets i can use keyword DSN and some other criteria but i am not sure how to implement it.
Can you please help me |
|
Back to top |
|
|
TheMFKid
New User
Joined: 20 Nov 2013 Posts: 91 Location: India
|
|
|
|
I am not sure if your requirement qualifies to do using Cobol, Might be REXX/Macro will be a better solution.
How big is your flat file?. Is this a one-time/daily/weekly/monthly activity? |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10891 Location: italy
|
|
Back to top |
|
|
sandeep kumar302
New User
Joined: 14 Mar 2012 Posts: 81 Location: India
|
|
|
|
Hi Mfkid,
I am suppose to develop a cobol program for this task. The flat files might contain more than 50000 jobs. . Even if I have a small and easy Rexx program then I can try to convince them for Rexx. |
|
Back to top |
|
|
sandeep kumar302
New User
Joined: 14 Mar 2012 Posts: 81 Location: India
|
|
|
|
Hi Enrico,
The Link which u provided me is very lenghthy one and as I told that I am new to writing cobol programs and Rexx programs. Please suggest the small cobol or rexx program which will work fine. |
|
Back to top |
|
|
Akatsukami
Global Moderator
Joined: 03 Oct 2009 Posts: 1787 Location: Bloomington, IL
|
|
|
|
You have been told -- both here and on our sister board -- that a quick, easy solution does not exist. Mr. Myers has pointed out some of the difficulties. You have taken a bite (or had it thrust into your mouth) that is too big for you to chew. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10891 Location: italy
|
|
|
|
Quote: |
Please suggest the small cobol or rexx program which will work fine. |
no small program will be able to parse and extract info from a JCL stream |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello and welcome to the forum,
As has been explained, it is not acceptable to post the same question in multiple forums. This topic is being locked.
As your experience level is on the low end, the "other" forum will be more suitable to help you with various kinds of questions.
Be aware that most of us senior "helpers" here support that forum as well, so you will have mostly the same answers anyway.
As explained, this will not be a trivial task (if done well).
If a working solution seems too complicated to download and run, you will be better working on something else until your experience level increases.
d |
|
Back to top |
|
|
|