Salesforce

DbExist (Magic xpa 4.x)

« Go Back

Information

 
Created BySalesforce Service User
Approval Process StatusPublished
Objective
Description

DbExist (Magic xpa 4.x)

Checks whether a specified data source exists on disk, and returns a logical TRUE or FALSE accordingly.

Syntax:

DbExist(number,file name)

Parameters:

number: A number that represents the data source's sequence number in the Data repository.

file name: This parameter is used as an alternative to number. If not needed, enter '' (two single quotation marks). If needed, enter an Alpha string that represents the data source specification. The string may contain a path. If the path is not indicated, Magic xpa assumes the current directory.

Returns:

Boolean (TRUE, FALSE)

Examples:

DbExist(1,") or DbExist('1'DSOURCE,") return TRUE if the data source exists on disk.

DbExist (1,'FSTFIL.DAT') attempts to check the first line of the Data repository, using the OS name 'FSTFIL' in the current directory.

Note:

Using the DSOURCE literal will ensure that the correct data source will be found even if the data source's position in the Data repository has changed. The data source sequence number and path behave exactly as defined in the Data repository.

DbExist with a data source number parameter of 0 (zero), or greater than the number of data sources in the Data repository, will always return FALSE.

Exceptions:

This function is not supported for Web Service databases.

See also:

DbDel, DbRecs, DbSize

The Online and Rich Client Samples projects (program SQ11 and RSQ11)

Reference
Attachment 
Attachment