SQL/MX 2.x Reference Manual (H06.04+)

Embedded-Only SQL/MX Statements
HP NonStop SQL/MX Reference Manual540440-003
3-63
INVOKE Directive
INVOKE Directive
Considerations for INVOKE
C Examples of INVOKE
COBOL Examples of INVOKE
The INVOKE preprocessor directive generates a C structure template or COBOL
record declaration that corresponds to a row in a specified table or view and inserts the
declaration directly into the host program. The row description includes a data item for
each column.
INVOKE is an SQL/MX extension.
table
is the name of an existing table or view for which to create a row description.
table can be one of these object names:
Guardian physical name
ANSI logical name
DEFINE name
See Database Object Names on page 6-12.
For more information on how the preprocessor expands table in the INVOKE
directive, see Preserving or Overriding the INVOKE Directive on page 3-65. For
more information on using a DEFINE name in the Windows NT environment, see
Using DEFINE Names in the Windows NT Environment on page 3-65.
AS record
specifies a host language identifier that is the name for the record definition or
structure declaration.
For C, the default structure name is the simple name of the table or view with the
suffix _type appended; for example: mytable_type.
INVOKE table
[AS record]
[DATEFORMAT {DEFAULT | EUROPEAN | USA}]
[PREFIX indicator-prefix]
[SUFFIX indicator-suffix]
[NULL STRUCTURE]
[CHAR AS {STRING|ARRAY}]
C/COBOL