Skip to content

Latest commit

 

History

History
39 lines (29 loc) · 1.96 KB

fetching-a-single-row-with-irow.md

File metadata and controls

39 lines (29 loc) · 1.96 KB
title description author ms.author ms.date ms.service ms.subservice ms.topic helpviewer_keywords
Fetch single row with IRow (OLE DB driver)
IRow allows direct access to columns of a single row object. The IRow interface in the OLE DB Driver for SQL Server is simplified to increase performance.
David-Engel
davidengel
06/14/2018
sql
connectivity
reference
fetching rows
IRow interface
single row fetching [OLE DB Driver for SQL Server]
OLE DB rowsets, fetching
rowsets [OLE DB], fetching
OLE DB Driver for SQL Server, fetching

Fetching a Single Row with IRow (OLE DB Driver)

[!INCLUDE SQL Server]

[!INCLUDEDriver_OLEDB_Download]

The IRow interface implementation in the OLE DB Driver for SQL Server is simplified to increase performance. IRow allows direct access to columns of a single row object. If you know beforehand that the result of a command execution will produce exactly one row, IRow will retrieve the columns of that row. If the result set includes multiple rows, IRow will expose only the first row.

The IRow implementation does not allow any navigation of the row. Each column in the row is accessed only one time with one exception: A column can be accessed one time to find the column size and again to fetch the data.

Note

IRow::Open supports only DBGUID_STREAM and DBGUID_NULL type of objects to be opened.

To obtain a row object using ICommand::Execute method, IID_IRow must be passed. The IMultipleResults interface must be used to handle multiple result sets. IMultipleResults supports IRow and IRowset. IRowset is used for bulk operations.

In This Section

See Also

Rowsets