Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Find the Copybook

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
meharnafis

New User


Joined: 28 May 2008
Posts: 5
Location: Noida

PostPosted: Wed Jun 10, 2009 3:21 pm    Post subject: Find the Copybook
Reply with quote

How to find out copy book for a dataset from the name of dataset used in the jcl only?
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Jun 10, 2009 3:30 pm    Post subject:
Reply with quote

Ask your peers how they do it. This is a site specific question.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Wed Jun 10, 2009 3:30 pm    Post subject: Reply to: Find the Copybook
Reply with quote

ask development support, they know about the environment
Back to top
View user's profile Send private message
meharnafis

New User


Joined: 28 May 2008
Posts: 5
Location: Noida

PostPosted: Wed Jun 10, 2009 3:41 pm    Post subject:
Reply with quote

This is one of the interview questions that I was asked.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Wed Jun 10, 2009 3:53 pm    Post subject: Reply to: Find the Copybook
Reply with quote

one of the most stupid questions asked... icon_evil.gif

You cannot do it

there could be zillions of datasets with the same layout ( using the same copybook )

only the operations and application documentation can tell
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Wed Jun 10, 2009 4:03 pm    Post subject:
Reply with quote

As this is an interview question, a lay man kind of answer can be -- Using ISPF 3.14, search the JCL in which this DSN is created/used, pick the DD name from there and search that DD name in the COBOL source library. You'll get the program using that DD name and so the layout.

For the sake of discussion, let's assume there is only one copybook per DSN -- though what Enrico has said is the actual and practical situation. This question is kind of BS for an interview.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Thu Jun 11, 2009 6:01 am    Post subject:
Reply with quote

A variation on Anuj's approach:

Once you find the dsn in the JCL (it will probable appear in more than 1 JOB or step), find the associated PGM that uses the DSN. Then look at the associated FD for the copybook. If not there, it's probably in WS. Check the READ/WRITE stmts for FROM/INTO.

I'll leave the rest up to you.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Jun 11, 2009 3:14 pm    Post subject:
Reply with quote

Thanks Jack -- that's rather straight forward. Not sure why did I not think to find the associated PGM that uses the DSN, ..mmmm... why in the heaven I thought to search in the "source-base-library" . . . icon_rolleyes.gif ... that's ofcourse time-consuming... icon_redface.gif
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Fri Jun 12, 2009 6:22 am    Post subject:
Reply with quote

Hi Anuj,

Thanx for the "attaboy". On another point, you said:
Quote:
This question is kind of BS for an interview

I don't know about that. Most pgmmrs spend a lot of time searching JCL/SOURCE Libs.

I think that if a pgmmr can't do that, (s)he operates under a handicap, so it might be something for an employer to look for.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts find RACF group for access to spooled... jzhardy JCL & VSAM 1 Mon May 08, 2017 11:46 am
No new posts To find out size allocated to a seque... ashek15 JCL & VSAM 15 Thu Apr 27, 2017 9:42 am
No new posts find particular member name in PDS us... ravi243 CLIST & REXX 10 Mon Dec 19, 2016 6:44 pm
No new posts How to find the first monday of the w... abdulrafi COBOL Programming 10 Fri Nov 25, 2016 3:24 pm
No new posts Find out a active PGM jpsager JCL & VSAM 10 Fri Oct 07, 2016 4:32 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us