Skip to content

Latest commit

 

History

History
72 lines (53 loc) · 2.47 KB

descriptor-transitions.md

File metadata and controls

72 lines (53 loc) · 2.47 KB
title description author ms.author ms.date ms.service ms.subservice ms.topic helpviewer_keywords
Descriptor Transitions
Descriptor Transitions
David-Engel
davidengel
01/19/2017
sql
connectivity
reference
state transitions [ODBC], descriptor
transitioning states [ODBC], descriptor
descriptor transitions [ODBC]

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
-- -- --