Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Static calling one db2 program gives plan error

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

New User


Joined: 31 Jan 2006
Posts: 49

PostPosted: Thu Jun 14, 2007 3:16 pm    Post subject: Static calling one db2 program gives plan error
Reply with quote

I am running one non db2 program, it is calling one db2 program, it is a static call. While running it is confusing with
plan and package. Let anyone tell me in run jcl which plan and which program name I have to give.
ie, //systsin dd *
dsn system(icon_cool.gif
run program(?) plan(?)

raj
Back to top
View user's profile Send private message

raghunathns

Active User


Joined: 08 Dec 2005
Posts: 127
Location: rochester

PostPosted: Fri Jul 06, 2007 10:33 pm    Post subject: Static calling one db2 program gives plan error
Reply with quote

create plan for your mainframe. Bind main program with calling program dbrm.
Back to top
View user's profile Send private message
Karthikshankar

New User


Joined: 29 Jun 2007
Posts: 2
Location: Pune

PostPosted: Thu Jul 12, 2007 4:08 pm    Post subject: Non-DB2 Module Calling a DB2 Module
Reply with quote

The Main Module is calling the sub program (which is a COBOL-DB2 program) in static/dynamic mode the following steps should be followed for compilation.

If Main COBOL Program is calling the Sub program (COBOL-DB2) in a static mode,

1.Compile the sub program separately. Since it is a COBOL-DB2 progra, it has to go through all the steps of compilation i.e Pre-compilation, Bind, & compile/Link.


2. Compile the main program. Since it's a pure COBOL program, it can be compiled using a normal COBOL compiler. The compiler would expect the load module of the sub program (which would have been created after the completion of step mentioned above) and picks it from the appropriate load library.

If Main COBOL Program is calling the Sub program (COBOL-DB2) in a dynamic mode,

1. Compile the sub program separately as mentioned above. i.e treat the program as a normal COBOL-DB2 program and compile it using the COBOL-DB2 compiler.

2. Compile the main program. Since the call is dynamic, the compiler would not expect the load module of the subroutine and compiles only the main program.

Finally in the RUN JCL, the following statement should be specified.

RUN PROGRAM (MAIN PROGRAM NAME) PLAN (SUB PROGRAM NAME).

This is a simple PLAN Bind procedure.

Note : The above can be accomplished also through Package Bind. Instead of creating plan for the sub-program, create a package and bind it against the application plan.
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 IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts How to write Rexx program to size and... sreejeshcs CLIST & REXX 14 Thu Oct 12, 2017 7:26 am
No new posts Accessing CICS tran with map from JCL... navdeepaggarwal CICS 5 Tue Oct 03, 2017 6:15 pm
No new posts FTP Skip or ignore error and process ... AJAYREDDY All Other Mainframe Topics 3 Wed Sep 27, 2017 8:12 pm
No new posts Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us