xHarbour Reference Documentation > Function Reference xHarbour Developers Network  

RddInfo()

Queries and/or changes configuration data of RDDs.

Syntax

RddInfo( <nDefine>, [<xNewSetting>], [<cRddName>] ) --> xOldSetting

Arguments

<nDefine>
This is a numeric parameter for which #define constants exist in the file DbInfo.ch. They identify the numerous settings that can be queried or changed for replacable database drivers (RDD9 and begin with the prefix RDDI_ (see below).
<xNewSetting>
<xNewSetting> is an optional argument specifying a new value for the RDD setting identified by <nDefine>. The data type for <xNewSetting> depends on the RDD setting to change (see below). If the RDD setting is READONLY, the parameter is ignored.
<cRddName>
<cRddName> is an optional character string with the name of the RDD to query or configure. It defaults to the return value of RddSetDefault().

Return

The function returns the value of the specified RDD setting which is set before the function is called.

Description

RddInfo() is a universal function managing numerous RDD settings available in xHarbour. If an RDD does not support a setting, it may create a runtime error or simply ignore the function call upon its own discretion. In the latter case, the return value of RddInfo() is NIL.

The constants that can be used for <nDefine> are listed below:

RDDI_BLOB_SUPPORT --> lIsBlobSupported (READONLY)

  The return value is .T. (true) when the RDD supports binary large objects (BLOBs), otherwise .F. (false) is returned. BLOBs are supported by the DBFBLOB RDD. Refer to function BlobDirectImport() for an example of BLOB usage.

RDDI_CANPUTREC --> lCanWriteData (READONLY)

  See also: function RddList(). The return value is .T. (true) when data can be written record-wise instead of field-wise to the file maintained by the RDD, otherwise .F. (false) is returned. Record-wise data storage is an internal optimization of an RDD.

RDDI_ISDBF --> lIsDbfSupported (READONLY)

  The return value is .T. (true) when the RDD supports databases in DBF file format, otherwise .F. (false) is returned.

RDDI_LOCKSCHEME [<nNewLockScheme>] --> nOldLockScheme

  See also: command SET DBFLOCKSCHEME. This setting queries or changes the locking scheme for SHARED database access in a multi user environment. Refer to the SET DBFLOCKSCHEME command for a description of locking schemes. The values that can be used for <nNewLockScheme> are the same #define constants as described with the command.

RDDI_MEMOBLOCKSIZE [<nNewBlockSize>] --> nOldBlockSize

  See also: command SET MEMOBLOCK. This setting queries or changes the default block size for memo fields to use by an RDD. If an RDD does not support memo fields, the return value is zero.

RDDI_MEMOEXT [<nNewFileExtension>] --> nOldFileExtension

  See also: command SET MFILEEXT. This setting queries or changes the default extension for memo files to use by an RDD. If an RDD does not support memo fields, the return value is an empty string ("").

RDDI_MEMOTYPE [<nNewMemoType>] --> nOldMemoType

  This setting queries or configures the default memo file format to use by an RDD when it creates a new database containing memo fields with the DbCreate() function. To change the default memo file format, #define constants from Dbinfo.ch must be used for <nNewMemoType>. They begin with the prefix DB_MEMO_. Supported memo file formats are DBT, FPT and SMT.

RDDI_MEMOVERSION [<nNewMemoVersion>] --> nOldMemoVersion

  This setting queries or configures the a subtype, or version, for FPT memo files. It can be set in addition to the memo type RddInfo(RDDI_MEMOTYPE, DB_MEMO_FPT). To change the subtype of the FPT memo file format, #define constants from Dbinfo.ch must be used for <nNewMemoVersion>. They begin with the prefix DB_MEMOVER_. Supported memo file subtypes are FoxPro, SIX and FLEX.

RDDI_ORDBAGEXT [<cNewFileExtension>] --> cOldFileExtension

  See also: function OrdBagExt(). This setting queries or changes the default extension for index files to use by an RDD. If an RDD does not support indexes, the return value is an empty string ("").

RDDI_TABLEEXT [<cNewFileExtension>] --> cOldFileExtension

  See also: function DbTableExt(). This setting queries or changes the default extension for database files to use by an RDD. If an RDD does not support database files, the return value is an empty string ("").

Info

See also:DbInfo(), DbOrderInfo(), DbRecordInfo(), RddList(), RddName(), RddSetDefault()
Category: Database drivers , Info functions , xHarbour extensions
Header:Dbinfo.ch
Source:rdd\dbcmd.c
LIB:xhb.lib
DLL:xhbdll.dll


Copyright © 2006-2007 xHarbour.com Inc. All rights reserved.
http://www.xHarbour.com
Created by docmaker.exe