|
|
DESCRIBE
DESCRIBE gathers information on the result-set or dynamic variable specifications in a prepared statement and places the information in an SQL descriptor area.
Usage
Description
Information concerning the prepared statement identified by statement-name is placed in the named SQL descriptor area.
The two forms: DESCRIBE statement... and DESCRIBE OUTPUT statement... are equivalent, and gather information on the items in the result-set of the statement and places it in the SQL descriptor area.
DESCRIBE INPUT statement... describes the statement's input and output variables.
DESCRIBE OUTPUT statement... describes the result-set returned by the statement.
If descriptions of both the result-set and the input variables are required for a prepared statement, the statement must be described separately with each form of DESCRIBE.
The descriptor-name is identified by a host variable or a literal.
See ALLOCATE DESCRIPTOR for a description of the SQL descriptor area.
See ALLOCATE CURSOR for a description of extended statements.
See also, GET DESCRIPTOR.
Restrictions
The DESCRIBE statement is only applicable to dynamically prepared SQL statements.
Examples
exec sql DESCRIBE OUTPUT stmt2 USING SQL DESCRIPTOR :SQLA1; exec sql ALLOCATE DESCRIPTOR 'DescrIn'; exec sql ALLOCATE DESCRIPTOR 'DescrOut'; exec sql PREPARE 'stmt X1' FROM :sqlstr; exec sql DESCRIBE INPUT 'stmt X1' USING SQL DESCRIPTOR 'DescrIn'; exec sql DESCRIBE OUTPUT 'stmt X1' USING SQL DESCRIPTOR 'DescrOut';For more information, see the Mimer SQL Programmer's Manual, Describing Prepared Statements.
Standard Compliance
|
Mimer Information Technology AB Voice: +46 18 780 92 00 Fax: +46 18 780 92 40 info@mimer.se |
|
|