Previous Topic Next topic Print topic


INTO

Retrieves one row of results and assigns the values of the items returned by an OUTPUT clause in a SQL Server INSERT, UPDATE, or DELETE statement to the host variables specified in the INTO list.

Syntax:

>>---EXEC SQL--.-------------------.---.------------.---->
               +-FOR :host_integer-+   +-AT db_name-+
           +- ,-+
           V    | 
 >---INTO--:hvar--result-set-generating-dml-statement---->

 >---END-EXEC---><

Parameters:

host_integer A host variable that specifies the maximum number of host array elements processed. Must be declared as PIC S9(4) COMP-5 or PIC S9(9) COMP-5.
db_name The name of a database that has been declared using DECLARE DATABASE.
hvar A host variable to store the ODBC connection handle. Must be declared as PIC X(4) COMP-5.
result-set-generating-dml-statement A SQL Server INSERT, non-positioned UPDATE, or DELETE statement with an OUTPUT clause.

Comments:

INTO is supported for SQL Server only.

Previous Topic Next topic Print topic