DBRBUF

Description

(UNIX only) Determine whether the DB-Library network buffer contains any unread bytes.

Syntax

DBBOOL DBRBUF(dbproc)
 
DBPROCESS     *dbproc;

Parameters

dbproc

A pointer to the DBPROCESS structure that provides the connection for a particular front-end/server process. It contains all the information that DB-Library uses to manage communications and data between the front end and server.

Returns

TRUE” (bytes remain in buffer) or “FALSE” (no bytes in buffer).

Note that DBRBUF actually returns “TRUE” both when there are bytes available in the read buffer, and when no more results are available to be processed.

This is because the purpose of DBRBUF is to tell an application when it can read and be assured that it will not hang. If DBRBUF did not return “TRUE” in the case of no more results, then applications that loop while DBRBUF returns “FALSE” could loop indefinitely, if all results had already been processed.

Usage

See also

DBIORDESC, dbpoll, dbsqlok, dbresults