Descriptor Transitions
ODBC descriptors have the following three states.
State | Description |
---|---|
D0 | Unallocated descriptor |
D1i | Implicitly allocated descriptor |
D1e | Explicitly allocated descriptor |
The following tables show how each ODBC function affects the descriptor state.
SQLAllocHandle
D0 Unallocated |
D1i Implicit |
D1e Explicit |
---|---|---|
D1i[1] | -- | -- |
D1e[2] | -- | -- |
[1] This row shows transitions when HandleType was SQL_HANDLE_STMT.
[2] This row shows transitions when HandleType was SQL_HANDLE_DESC.
SQLCopyDesc
D0 Unallocated |
D1i Implicit |
D1e Explicit |
---|---|---|
(IH) | -- | -- |
SQLFreeHandle
D0 Unallocated |
D1i Implicit |
D1e Explicit |
---|---|---|
--[1] | D0 | -- |
(IH)[2] | (HY017) | D0 |
[1] This row shows transitions when HandleType was SQL_HANDLE_STMT.
[2] This row shows transitions when HandleType was SQL_HANDLE_DESC.
SQLGetDescField and SQLGetDescRec
D0 Unallocated |
D1i Implicit |
D1e Explicit |
---|---|---|
(IH) | -- | -- |
SQLSetDescField and SQLSetDescRec
D0 Unallocated |
D1i Implicit |
D1e Explicit |
---|---|---|
(IH)[1] | -- | -- |
[1] This row shows transitions when DescriptorHandle was the handle of an ARD, APD, or IPD, or (for SQLSetDescField) when DescriptorHandle was the handle of an IRD and FieldIdentifier was SQL_DESC_ARRAY_STATUS_PTR or SQL_DESC_ROWS_PROCESSED_PTR.
All Other ODBC Functions
D0 Unallocated |
D1i Implicit |
D1e Explicit |
---|---|---|
-- | -- | -- |