In this lesson, you will learn how to use DFXray to inspect table definitions within a workspace, understand the filtering and navigation options in the table selector, and explore useful features like relationship diagrams, source code references, and exporting data. You will also see how DFXray handles different database backends, such as DataFlex tables and SQL, and how to efficiently search and navigate column data.
Start DFXray and Open Workspace
Launch DFXray and select the Trex workspace.
The workspace is opened, tables are read, and the database is closed to avoid conflicts if tables are edited in Studio while DFXray is open.
Reread Workspace Data
If tables are edited in Studio, use Files > Reread Workspace to refresh data in DFXray.
Table List Panel
Displays all tables in the workspace.
Shows record counts and which drivers are used (e.g., DataFlex tables).
Filtering options are available for table names.
Relationship Indicators and Navigation
Selecting a table (e.g., Company) shows its parent and child relationships visually.
Use this to navigate through related tables up and down.
Right-click a table to open it in DB Explorer or find source code references.
Source Code References
Quickly locate all references to a selected table in the source code.
DFXray found 316 references in 56 packages in this example.
Navigate through hits using F7 and F8 keys.
Double-click a reference to open the Studio at the exact package and line.
Export Table List to Notepad
Write the current table list content to Notepad for copying into documentation or source code.
Relationship Diagram
Located at the bottom left of the panel.
Shows a visual diagram of table relationships for an overview of the database structure.
Uses an external service (yuml.me) to generate diagrams, sending only necessary relationship data, no details.
Switch Workspace to SQL Backend
Open a workspace with an SQL backend (e.g., Chatbox).
Tables show SQL drivers and DataFlex data types (ASCII, numeric, etc.).
Viewing Column Details
Select a table and see all columns with their DataFlex types.
The last column shows the native field type name from the database backend.
Export Column Data
Use shortcut (Ctrl + W) to export column info to Notepad for easier viewing.
Searching Columns in Source Code
Right-click a column to find it in DataFlex source or to find similar column names using wildcards (* and ?).
Examples shown: searching for “login name” and columns ending with “ID”.
This helps quickly locate columns across tables.
Summary
The section covered using the table selector, filtering, relationship navigation, source code references, exporting data, and working with different backends.
Next up are additional features DFXray offers beyond table selection.
DFXray is built and presented by Sture Andersen from Sture ApS.