Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Artful Two for Clipper 5.0 - Norton Guide http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]

Syntax

DB_OPEN( cDbf_name[, nIndexes[, acIndex_key ;
         [, cAka[, lQuick[, alUnique ;
         [, lKillntxs[, lExclusive ]]]]]] )

Purpose

Check header integrity and open a dbf and its indexes. DB_OPEN() does
not require a dictionary.

Arguments

     cDbf_name -- name of the .dbf

     nIndexes -- number of indexes to open - defaults to none

     acIndex_key -- single key, or array of keys - defaults to none

     cAka -- alias for the file - defaults to cDbf_name

     lQuick -- optional logical - if .T., skip CHK_DBF(), else do it

     alUnique -- optional - logical or array of them to make unique
                     indexes

     lKillntxs -- optional logical - if passed and .T., unconditionally
                      re-index all files, else re-index only if an index is
                      missing or corrupt

     lExclusive -- if passed and .F., open in SHARED mode, otherwise
                       open EXCLUSIVE.

Setup

DB_OPEN() does not support path prefixes for DBFs
or indexes; only DICTOPEN() does.

Example

     IF !DB_OPEN( "Customer", 1, "Account_no" )
        QUITPROG()
     ENDIF

Returns

.T. if the file and index(es) are sound and opened successfully, otherwise
.F.

Side Effects

Rebuilds indexes if they are corrupted or missing.

Artful Calls

FILEFOUND, CHK_DBF, CHK_NTX, SET_INDEX, STRINT, (multi-user only)
MUSE, LOCKFILE

Source Files

AA_DBOPN.PRG, AM_DBOPN.PRG

See Also: CHK_DICT() CHK_DBF() CHK_NTX() DDB_OPEN() DICTOPEN() SET_INDEX()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson