DataFlex maintains a list of tables in a special file called (by default) FILELIST.CFG. This filelist file must be found to run or compile DataFlex programs that access data. The file is found at the Filelist: location specified in the workspace configuration file. You can set the file that your program uses as the filelist as it runs by use of the set_filelist command, and query it with get_filelist. With this command, the name of the file may be set to any name you desire.
The file list links together four of a table's attributes: the DataFlex name, filelist number, user-display name and physical name, optionally including the path. A tables' user-display name is displayed in the Studio, Database Builder and other tools, where it may be modified. Since user-display names can be up to 40 characters long, they can, and should, contain a good description of the table’s purpose, contents, ownership, and other pertinent information.
Running programs normally access database files by their filelist numbers. When a program is being compiled, the compiler finds the table’s definition, including its number, in the table’s FD file, and replaces the table and column names in the source code with numbers in the compiled application. When the program is running, these numbers are used to find the physical names of the tables in the file list. Table and column numbers are sometimes explicitly used in source code.
If the filelist contains no directory path for a table, the runtime searches the directory(ies) identified in the Data: value specified in the workspace configuration file.
If your requirements exceed the supported range of a single filelist, then you may use multiple filelists, and you can have tables open concurrently from more than one filelist. A large application may even have its own filelist. If a program is run or compiled with different filelists having conflicting assignments of names or numbers, however, serious problems can arise.
Accessing File Lists
Methods of Accessing Tables