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
 

 

Multiple COBOL-DB2 pragrams calling by different plan

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
deepak_shrivastava

New User


Joined: 05 Jan 2016
Posts: 8
Location: India

PostPosted: Wed Jan 06, 2016 3:45 pm    Post subject: Multiple COBOL-DB2 pragrams calling by different plan
Reply with quote

Hi All,

I have one scenario, it will be great if some one advice and answer.

I have below 4 programs
PROG1(COBOL Program).
PROG2(COBOL-DB2 Program) uses DB2 Plan ABC123.
PROG3(COBOL Program).
PROG4(COBOL-DB2 Program) uses DB2 Plan XYX456.

If PROG1 call PROG2 and PROG2 call PROG3 and PROG3 call PROG4.
(PROG01->PROG02->PROG03->PROG04)

While calling from JCL we usually write as below
//BLASTP00 EXEC PGM=IKJEFT01,REGION=6M,TIME=60,
// PARM=('%DB2EXECE SY(DB2C) PL(ABC123) PR(PORG1)')

But How to pass Plan name for PROG4 ?
How PROG02 will get plan name from base program PORG1 ?
Back to top
View user's profile Send private message

Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1653
Location: NY,USA

PostPosted: Wed Apr 20, 2016 8:26 pm    Post subject:
Reply with quote

I hope by now you got it working and understand how it works but to answer the post, each program (or subprogram) that contains SQL needs to be pre-processed to create a DBRM. The DBRM is then bound into a PLAN that is accessed by a LOAD module at run time to obtain the correct DB/2 access paths for the SQL statements it contains.

The basic process remains the same - you need a PLAN to run the program and check PLANs + COLLECTIONs + VERSIONs + PACKAGEs + DBRMs = Confusion to avoid anymore confusion.
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 -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts RULES(NOEVENPACK) in cobol jackzhang75 COBOL Programming 5 Wed Mar 29, 2017 12:47 am
No new posts Data replication from multiple Db2 ta... kishpra DB2 5 Mon Mar 27, 2017 9:58 pm
No new posts Unable to catalog a gdg dataset resid... Shovan JCL & VSAM 7 Fri Mar 24, 2017 2:24 pm
No new posts To display values of multiple rows in... vinu78 DB2 2 Thu Mar 09, 2017 1:20 pm
No new posts SQL query not working in Cobol program. CuriousMainframer COBOL Programming 14 Wed Feb 22, 2017 5:56 pm


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