[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1204
  • Last Modified:

Does DB2 (exec sql) change any EIB fields in CICS?

I have a program that runs CICS applications under TSO on IBM's Z/OS operating system. My program is called KICKS ( http://home.gci.net/~mike-noel/KICKS ).
I'm doing a demonstration of DB2 support under KICKS and have gotten a question I can't answer.
In 'real' CICS, does an EXEC SQL ever modify any EIB field (eibresp, eibresp2, eibfn, ...)? I think the answer is 'NO', but have been unable to find a definitive answer. Does anyone (a) know of a statement in any IBM publication where it says EIB fields are (or are not) modified? or (b) have an example showing some EIB field that is modified?
0
mikenoel
Asked:
mikenoel
  • 3
  • 3
  • 2
  • +2
1 Solution
 
Kent OlsenData Warehouse Architect / DBACommented:
Hi Mike,

Items in an EIB may change, but not because of anything that DB2 does.  An EIB is a CICS buffer and contains information about the CICS session.  An SQLCA is a DB2 buffer and contains information about the DB2 session.

Here are a couple of descriptions of the EIB, from other articles:

An EIB is a CICS area that contains information related to the current task, which can be used for debugging the program. The most widely used variables are EIBDATE, EIBTIME, EIBAID, EIBCALEN, EIBCPOSN, EIBRESP, EIBRSRCE (resource), EIBFN (recent CICS command code), EIBTRMID and EIBTRNID.

The EXEC Interface Block (EIB) is the main means of communication between an application program and CICS. It includes fields that identify the transaction code, terminal and number of the current task. The EIB also has fields containing the results of the execution of CICS commands.


If something in the EIB changes, it's because the CICS session changed it.

Good Luck,
Kent
0
 
mikenoelAuthor Commented:
Thanks Kent. I think you are right "If something in the EIB changes, it's because the CICS session changed it" - ie - not an exec sql. However I'm seeking an authorative answer. Can you site an IBM reference? Best, Mike
0
 
Kent OlsenData Warehouse Architect / DBACommented:
Hi Mike,

I don't know of a document that draws that line in the sand.  However, DB2 communicates via the SQLCA (SQL Communications Area).  I'm unaware of any mechanism to use the EIB for DB2 communications.


Kent
0
Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

 
giltjrCommented:
You can read http://examples.oreilly.com/cics/CDROM/pdfs/cicsts/dfhg300.pdf

This is just one place you can read what EIB is and used for.

I am fairly sure that the EIB field is not for use by the program that is executed when you do an EXEC xxxx.  It is for use by CICS to show you the results of EXEC xxxx.  If the program xxxx wants to return a code, it needs have an work area that it uses to pass information back and forth to the calling program.
0
 
mikenoelAuthor Commented:
Thanks giltjr. I'd accept the Oreilly book as authorative (I think it's actually written by IBM) but I don't think it addresses my question. Actually, it scarcely mentions DB2. Best, Mike
0
 
giltjrCommented:
Um, I guess it depends on how you look at it.  The lack of mentioning DB2 (or any other program) should tell you that they can't modify EIBRESP/EIBRESP2.  

Look at the codes for EIBRESP/EIBRESP2, they are all defined because CICS knows what they can be.  Is there any mention of "user" codes?

Since you seem to know your way around CICS, could you write a program that modifies EIBRESP/EIBRESP2?  I not really a CICS person, but have worked with it a little and I always thought EIBRESP/EIBRESP2 were read only from an application point of view.
0
 
Kent OlsenData Warehouse Architect / DBACommented:
Hi Mike,

Think about how these buffers are used.  When the program issues a DB2 call, the SQLCA block is passed to DB2.  The EIB is not.  DB2 doesn't know anything about it.

CICS may check the results of the call to DB2 and update the EIB, (I don't know about that), but since DB2 doesn't know the address of the EIB, it's not possible for DB2 to modify it.


Kent
0
 
mikenoelAuthor Commented:
Thanks Kent, giltjr; I think it's risky to infer something from silence. And you can see there is SOME coupling between cics and db2 from the fact that cedf traps exec sql's. So while I accept that db2 itself wouldn't modify the eib, it certainly would be possible for cics to do so thru the interface. That said, I have it from a former hersley guy (outside ee) that in fact cics does not, so I guess I should close this question. Thanks for your replies. Best, Mike
0
 
tliottaCommented:
You can't expect that documentation would list processes that 'do not' affect some element. The lists would overwhelm all other documentation.

Tom
0
 
ee_autoCommented:
Question PAQ'd and stored in the solution database.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
  • 3
  • 2
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now