2.2.7.7 DONE
Token Stream Name
-
DONE
Token Stream Function
Indicates the completion status of a SQL statement.
Token Stream Comments
The token value is 0xFD.
This token is used to indicate the completion of a SQL statement. Because multiple SQL statements can be sent to the server in a single SQL batch, multiple DONE tokens might be generated. In this case, all but the final DONE token will have a Status value with the DONE_MORE bit set (details follow).
A DONE token is returned for each SQL statement in the SQL batch, except for variable declarations.
For execution of SQL statements within stored procedures, DONEPROC and DONEINPROC tokens are used in place of DONE tokens.
Token Stream-Specific Rules
-
TokenType = BYTE Status = USHORT CurCmd = USHORT DoneRowCount = LONG
Token Stream Definition
-
DONE = TokenType Status CurCmd DoneRowCount
Token Stream Parameter Details
Token stream parameter details are described in the following table.
Parameter |
Description |
---|---|
TokenType |
DONE_TOKEN |
Status |
The Status field MUST be a bitwise "OR" of the following:
|
CurCmd |
The token of the current SQL statement. |
DoneRowCount |
The count of rows that were affected by the SQL statement. The value of DoneRowCount is valid only if the value of Status includes DONE_COUNT. |