dbgetrow

Reads the specified row in the row buffer.

Syntax

STATUS dbgetrow (
PDBPROCESS
dbproc,
DBINT
row );

where

dbproc
Is the DBPROCESS structure that is the handle for a particular workstation/ SQL Server process. It contains all the information that DB-Library uses to manage communications and data between the workstation and SQL Server.
row
Is the number of the row to read. The first row returned from SQL Server is number 1.

Returns

One of four different types of values:

Remarks

The dbgetrow function sets the current row to a specific row and reads it. This function only works if the DBBUFFER option is on. Any specified binding of row data to program variables takes effect.

When buffering is not turned on, normally each row is processed, in turn, by repeatedly calling dbnextrow until it returns NO_MORE_ROWS. When buffering is turned on, dbgetrow allows the user to jump to any row that has already been read using dbnextrow and is still in the row buffer. Calls to dbnextrow after a dbgetrow call return rows in order, following the row read by dbgetrow.

See Also

dbaltbind, dbbind, dbclrbuf, dbnextrow, Bulk-Copy Functions, and DB-Library Options