Description
Returns information about the tables in a specified volume.
Syntax
returnValue = List_Volume_Sub(volume, database, returncolumnlist, sortlist)
Parameters
The List_Volume_Sub routine has the following parameters.
Parameter | Description |
---|---|
volume | Specify 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. |
database | Specifies a database name. If database is not specified, information about all databases that contain information about volume are returned. |
returncolumnlist | Specifies 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) |
Sortlist | Specifies 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.
Returns
An @fm delimited list of data based on the returncolumnlist parameter.
See Also
Example
declare function List_Volume_Sub volumeList = List_Volume_Sub("DATAVOL","","TABLE_NAME":@fm:"TABLE_FOREIGN_NAME","")
1 Comment
Don Bakke
The SortList argument is required even if no sorting is needed. Otherwise a VNAV error will occur.