[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
DBRECORDINFO()
Return and optionally change information about a record
------------------------------------------------------------------------------
Syntax
DBRECORDINFO(<nInfoType>,
[<nRecord>],
[<expNewSetting>]) --> uCurrentSetting
Arguments
<nInfoType> determines the type of information, as specified by the
constants below. Note, however, that not all constants are supported
for all RDDs. These constants are defined in the Dbinfo.ch header file,
which must be included (#include) in your application.
Record Information Type Constants
------------------------------------------------------------------------
Constant Description
------------------------------------------------------------------------
DBRI_DEL Deleted flag status of the record
DBRI_LOCK Locked flag status of the record
DBRI_SIZE Length of the record
DBRI_RECNO Position of the record
DBRI_UPDAT Updated flag status of the record
------------------------------------------------------------------------
Important! DBI_USER is a constant that returns the minimum value
that third-party RDD developers can use for defining new <nInfoType>
parameters. Values less than DBI_USER are reserved for Computer
Associates development.
<nRecord> is the record to obtain information. If omitted, the
current record is used.
<expNewSetting> is reserved for RDDs that allow the file information
to be changed, in addition to being retrieved. None of the RDDs
supplied with CA-Clipper support this argument. It can be omitted or
specified as NIL.
Returns
If <expNewSetting> is not specified, DBRECORDINFO() returns the current
setting. If <expNewSetting> is specified, the previous setting is
returned.
Description
DBRECORDINFO() retrieves information about the state of a record (row).
The type of information is specified by the <nInfoType> parameter. By
default, this function operates on the currently selected record.
DBRECORDINFO() is designed to allow for additional <nInfoType> values
that can be defined by third-party RDD developers.
Examples
. The following example uses DBRECORDINFO() to retrieve field
information:
#include "Dbinfo.ch"
DBRECORDINFO(DBRI_SIZE) // Same as RECSIZE()
DBRECORDINFO(DBRI_LOCK, 200) // Is record 200 locked?
DBRECORDINFO(DBRI_DEL, 201) // Is record 201 locked?
DBRECORDINFO(DBRI_UPDAT) // Is the current record
// updated?
DBRECORDINFO(DBRI_RECNO, 230) // On which position is
// record 230?
// If no orders are active,
// the position is 230;
// otherwise, the relative
// position within the order
// will be returned.
Files Library is CLIPPER.LIB, header file is Dbinfo.ch.
See Also:
DBFIELDINFO()
DBINFO()
DBORDERINFO()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson