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
 

 

DD names for twin alternate indexes.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Yvonne1980

New User


Joined: 31 Aug 2010
Posts: 20
Location: Edinburgh

PostPosted: Mon Jul 04, 2011 8:11 pm    Post subject: DD names for twin alternate indexes.
Reply with quote

I have two separate but similar VSAM files, both ha ve alternate indexes that I need to read and update.

These are widely used VSAMs within our system and always have the same DD names: GN70178T and GN70178S. I am in the rare situation of requiring to access them both in the same program. Normally for base cluster DD names that are already 8 chars long, the alternate index DD name is the base cluster with the last char replaced with a '1'. In my case this means I would have two identically named DD names in the same step: GN701781 (different dataset names).

Before I code and test this does anyone know if the operating system will associate the correct DD to the correct cluster ?, Is the fact that the declaration of the alternate index occurs immediately after the main cluster declaration enough ?

Many thanks.
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Mon Jul 04, 2011 8:26 pm    Post subject: Reply to: DD names for twin alternate indexes.
Reply with quote

no ... for jcl contigous-ness has no meaning ...
what counts are just ... guess what icon_biggrin.gif ... the ddnames
and the choice is completely up to You

but i beg to differ a bit on the terminology ...

cluster .... the <base thing>
alternate index ... <another thing>
PATH what lets You access the cluster thru an alternate index

usually the program and the jcl should not be concerned with the alternate index <thing>

just the BASE cluster and the PATH
Back to top
View user's profile Send private message
Yvonne1980

New User


Joined: 31 Aug 2010
Posts: 20
Location: Edinburgh

PostPosted: Mon Jul 04, 2011 8:43 pm    Post subject:
Reply with quote

Enrico,

Yes, I'm talking about the JCL declaration for the Path that relates to the alternate index. In this case I am restriced in my choice of DD names due to installation 'rules'.

Can you tell me if my multiple use of the same DD name (//GN701781) will cause a problem. Here is an example of what the JCL would look like:
Code:

//GN70178T DD DSN=MY.VSAM.GN70178T,           
//            DISP=OLD                       
//GN701781 DD DSN=MY.VSAM.GN70178T.PATH,     
//            DISP=OLD                       
//GN70178S DD DSN=MY.VSAM.GN70178S,           
//            DISP=OLD                       
//GN701781 DD DSN=MY.VSAM.GN70178S.PATH,     
//            DISP=OLD                       
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Mon Jul 04, 2011 8:47 pm    Post subject: Reply to: DD names for twin alternate indexes.
Reply with quote

Code:
In this case I am restriced in my choice of DD names due to installation 'rules'.


but the use of the same DDNAME to refer to different things is a NO NO

just shoot the idTENt who set the installation rules icon_biggrin.gif
I wonder why those people lack completely the flexibility to adapt to exceptions

one of the rules when setting the rules is ... never use all the <space/characters> available icon_cool.gif
maybe Murphy can provide some words of wisdom on the issue
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7251

PostPosted: Tue Jul 05, 2011 6:01 am    Post subject: Reply to: DD names for twin alternate indexes.
Reply with quote

A wacky solution would be to code the second file as ending in "2" instead of "1".

If it were me, I'd take the "problem" to my boss, so that he (or his boss or whoever) can take it to to the boss of the "standards" and get an "official" answer for you. Your "problem" is that it is impossible to produce valid code or JCL and follow the standards, so it is delaying development, and therefore implementation. Should also ask for all the naming standards to be reviewed along the lines enrico suggests at the same time.

I prefer this sort of memo to actual "shooting" (embarrassment to the offender, without prison sentence for you), but otherwise agree with enrico.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Tue Jul 05, 2011 8:06 am    Post subject: Reply to: DD names for twin alternate indexes.
Reply with quote

Quote:
A wacky solution would be to code the second file as ending in "2" instead of "1".


Nahhh Bill! how do You dare ? icon_biggrin.gif
a ddname ending with 2, according to the rules,
is the access path to the first file thru the second alternate index icon_cool.gif
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7251

PostPosted: Tue Jul 05, 2011 11:40 am    Post subject: Reply to: DD names for twin alternate indexes.
Reply with quote

enrico, after reading yours I thought 7, then, better, Q.

Then I realised Q would be for datasets accessed via 3rd alternate index on Thusday's only.

No way we can be wacky at all. icon_smile.gif
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Variable for cursor names ravikumar15 DB2 5 Sun Jul 17, 2016 7:08 am
No new posts Several errors during building altern... Andi1982 JCL & VSAM 11 Wed Jul 06, 2016 7:39 pm
No new posts Drop building Alternate Index for a p... bhavin.mehta JCL & VSAM 6 Mon Jul 04, 2016 3:47 pm
No new posts Using Field names in FILEAID Batch CO... Atul Banke Compuware & Other Tools 2 Wed Jun 29, 2016 9:54 pm
No new posts VSAM Alternate Index in CICS jacobdng CICS 2 Fri May 06, 2016 1:41 pm


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