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
 
Database access from COBOL

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

New User


Joined: 03 Feb 2006
Posts: 8

PostPosted: Wed Jan 27, 2016 11:33 am    Post subject: Database access from COBOL
Reply with quote

Hello All,

I have a question related to COBOL DB2 program in two different application.
I have a COBOL program (PGM-A) which belongs to Application-1. This program requires some data from Application-2. PGM-A calls to PGM-B (COBOL module). PGM-B calls to PGM-C(COBOL + DB2 module). PGM-B and PGM-C belongs to Application-2.
PGM-C gets the data from application-2 database(DB2) and pass it back to PGM-B and PGM-B then forwards it to PGM-A.
Question:
1. When PGM-A doesnt have authority to access Application-2 database, how its gets the data.
2. How can we restrict PGM-A accessing data from Application-2.
3. When PGM-A is being invoked from JCL, do we need to pass IKJEFTO1 inputs (program, plan) etc or it can be invoked directly by PGM=PGM-A
Back to top
View user's profile Send private message

Jiri Vandas

New User


Joined: 18 Aug 2014
Posts: 1
Location: Czech Republic

PostPosted: Wed Jan 27, 2016 8:37 pm    Post subject:
Reply with quote

Quote:
3. When PGM-A is being invoked from JCL, do we need to pass IKJEFTO1 inputs (program, plan) etc or it can be invoked directly by PGM=PGM-A


It can be invoked directly, but still you'll need to know destination DB2 system and plan name.

Please check Connecting to DB2 from your application program in DB2 doc
http://www-01.ibm.com/support/knowledgecenter/SSEPEK_11.0.0/com.ibm.db2z11.doc.apsg/src/tpc/db2z_connectapplication.html?lang=en
chapter Call attachment facility (CAF)

Basically you need to add into PGM-A commands CONNECT ssid and OPEN plan calls. Also don't forget CLOSE and DISCONNECT icon_smile.gif The way how you pass these parameters (ssid/plan) to your application is up to you.
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
This topic is locked: you cannot edit posts or make replies. Cobol to fetch the content by using s... arunc55 COBOL Programming 4 Fri Nov 17, 2017 1:25 pm
No new posts VBS and VB, COBOL syntax is the same ... natt.sut COBOL Programming 3 Sun Nov 12, 2017 6:36 am
No new posts COBOL - EXIT statement weird behavior anthony.pangestu COBOL Programming 0 Fri Oct 27, 2017 9:57 am
No new posts IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts User access certification In Mainfram... Virendra Shambharkar All Other Mainframe Topics 4 Tue Oct 03, 2017 12:32 pm

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