
INCLUDE
The INCLUDE statement inserts application code, including declarations and statements, into a source program.
Invocation
This statement can be embedded only in a COBOL application program. It is not an executable statement.Syntax
>>-INCLUDE--+-SQLIMSCA----+------------------------------------>< +-SQLIMSDA----+ '-member-name-'
Description
The following keyword parameters are defined for the INCLUDE statement:- SQLIMSCA
- Indicates that the description of
an SQL communication area (SQLIMSCA) is to be included. INCLUDE SQLIMSCA
must not be specified more than once in the same application program.
In COBOL, INCLUDE SQLIMSCA must be specified in the Working-Storage
Section or the Linkage Section.
For a description of the SQLIMSCA, see SQL communication area (SQLIMSCA).
- SQLIMSDA
- Indicates that the description of an SQL descriptor area (SQLIMSDA) is to be included. For a description of the SQLIMSDA, see SQL descriptor area (SQLIMSDA).
- member-name
- Names a member of the partitioned data set to be the library input
when your application program is prepared (with the IMS™ coprocessor). It must be an SQL identifier.
The member can contain any host language source statements and any SQL statements other than an INCLUDE statement. In COBOL, INCLUDE member-name must not be specified in other than the Data Division or the Procedure Division.
Notes
When your application program is prepared (with the IMS coprocessor), the INCLUDE statement is replaced by source statements. Thus, the INCLUDE statement must be specified at a point in your application program where the resulting source statements are acceptable to the compiler.
The INCLUDE statement cannot refer to source statements that themselves contain INCLUDE statements.
Example
Include an SQL communications area in a COBOL program.
EXEC SQLIMS INCLUDE SQLIMSCA END-EXEC.

