SQL/MP Reference Manual
HP NonStop SQL/MP Reference Manual—523352-013
I-4
Examples—IN
Examples—IN
This example finds those items whose number is 39, 337, or 452:
EMPNUM IN (39, 337, 452)
The example finds those items whose part number is not in the PARTLOC table:
PARTNUM NOT IN (SELECT PARTNUM
 FROM INVENT.PARTLOC)
INCLUDE SQLCA Directive
INCLUDE SQLCA is a host program directive that declares the SQL communication 
area (SQLCA) in a host program.
The SQLCA is a status-checking area for host programs. SQL clears and reinitializes 
the SQLCA before each SQL statement executes. After the statement executes, SQL 
stores information about the success or failure of the statement in the SQLCA, 
including error and warning codes and messages.
For more information about the contents and usage of the SQLCA, see the SQL/MP 
programming manual for your host language.
Consideration—INCLUDE SQLCA
By default, INCLUDE SQLCA declares a Version 2 SQLCA. To request a different 
version, use INCLUDE STRUCTURES before INCLUDE SQLCA. 
Example—INCLUDE SQLCA
This directives declare a version 315 SQLCA in a program:
EXEC SQL INCLUDE STRUCTURES ALL VERSION 315;
EXEC SQL INCLUDE SQLCA;
INCLUDE SQLDA Directive
INCLUDE SQLDA is a dynamic SQL directive that declares an SQL descriptor area 
(SQLDA) and optional names and collation buffers in a host program that uses 
dynamic SQL.
SQL uses the SQLDA with the dynamic SQL statements DESCRIBE and FETCH (to 
pass information about output columns) and DESCRIBE INPUT and EXECUTE (to 
pass information about input parameters). SQL uses the names buffer and collation 
buffer—which you can declare separately or with INCLUDE SQLDA—to pass column 
names and collation information returned by DESCRIBE and to pass input parameter 
names returned by DESCRIBE INPUT.
INCLUDE SQLCA










