Description

Returns information about the tables in a specified volume.

Syntax

List_Volume(volume, database, returncolumnlist, sortlist)

Parameters

The List_Volume routine has the following parameters.

ParameterDescription
volumeSpecify the volume name or the operating system path and drive identifier. If null, the value used is that of Data Path, in the Default Directories group of the Environment Management dialog box, reached from Database Manager.
databaseSpecifies a database name. If database is not specified, information about all databases that contain information about volume are returned.
returncolumnlistSpecifies a column name or an @fm delimited list of columns names to return. Column names are defined in SYSDICT. The column TABLE_NAME is returned by default. The following columns can be returned:

TABLE_NAME (default)

TABLE_DATABASE_ID

TABLE_FOREIGN_NAME

(Starting with Version 4.1.2) TABLE_MFS (list of all MFSs on the listed files)

SortlistSpecifies a column name or list of column names to sort by. If null, no sorting takes place.

In BASIC+, the list of volumes is stored in the system global variable @Volumes. Specific information can be selected and/or read from the SYSVOLUMES table.

Note

Starting with Version 4.1.2, the default behavior of the LIST_VOLUME routine has been changed. If no return information or sort order is specified, the command will now return the table name, database name, foreign name, and MFSs, and if no sort order is specified the results will be sorted by Table Name. LIST_VOLUME now accepts an additional argument in the Return Column list- TABLE_MFS, which will return all MFSs on the files listed.

The results of the routine are returned to the SYSTEM "RECEIVER" control.

See Also

List_Volume_Sub()functionRECEIVER property

Example: Listing Tables On Another Computer

RUN LIST_VOLUME '\\COMPAQ\COMPAQ\REVSOFT41\OI32BIT\LAB'

(starting with Version 4.1.3) lists the tables in the folder COMPAQ\REVSOFT41\OI32BIT\LAB on the \\COMPAQ computer, using the UNC notation.

Example: A List Entry Returned by List_Volume

run List_Volume "DATAVOL"

(starting with Version 4.1.2) returns a list of tables in the DATAVOL volume, each line formatted similar to:

CUSTOMERS, EXAMPLES, REV53082, SI.MFS, XQ.MFS

where:

CUSTOMERS is the table name

EXAMPLES is the database name

REV53082 is the operating system name corresponding to the CUSTOMERS table

SI.MFS, XQ.MFS are the MFSes applied to the CUSTOMERS table

  • No labels