Can SQL statements/queries be included in a copybook?
Answers were Sorted based on User's Feedback
Answer / tom
Yes, if the copybook is included with the precompiler
directive EXEC SQL INCLUDE. No, if one attempts to include
the copybook with a COBOL COPY directive.
| Is This Answer Correct ? | 5 Yes | 2 No |
Answer / ekalavya
The DB2 related things have to be included with the pre
compiler directive
EXEC SQL
INCLUDE XYZ
END-EXEC
But not like COPY XYZ.
This is because COPY statements are expended during
Compilation step, but the DB2 related items should be
available in pre-compilation step inorder to create DBRM
module, which is the input for Binding process into
PLAN/PACKAGE.
| Is This Answer Correct ? | 0 Yes | 0 No |
db2 maintains information about the data... a.in tables. b.in a set of tables known as db2 catalog. c.in db2 database. d.none of the above.
Hi , I am posting some interview ques . what is the use of cursors ? what is the diff between select and cursor ? bith are used for data retrival .. rite?
What is a lock?
My cobol program(not having any sql statements) is calling another cobol program ( having sql statements), what is needed for compilation and run in jcls .
Why do we need reorg in db2?
difference between group clause and order clause
What are foreign keys?
What are the different types of base tables?
What will the DB2 optimizer do?
What is IMAGECOPY ?
how to execute qcmdexc in rpgle?plz write code also?
What is the physical storage length of the data types date, time, and timestamp?