Unused VCL Units Profiler Results - Database Structure

Applies to AQTime 8.81, last modified on January 18, 2022

Results generated by the Unused VCL Units profiler are stored in a number of tables in the specified database. The contents of most of these tables correspond to the contents of AQTime panels in which profiling results are stored. This topic describes the structure of the database that stores exported Unused VCL Units profiler results.

The database contains the following tables:

The relationship between the mentioned tables is illustrated in the image below. This relationship is similar to the relationship of the data in AQTime’s Report and Details panels that contains the Unused VCL Units profiler results.

Relations Between Database Tables

The “root” table of the database is the INSTANCES table. It contains the list of all exported result sets and is shared by profilers. Each result set is identified by the INST_ID column value, which is unique among the table. All other database tables also have the INST_ID column that indicates the result set to which data of a specific table item belongs.

The UNUSED_VCL_UNITS_PROFILER_SOURCE_FILES_DATA table corresponds to the result set that is displayed in the Report panel. Each row in this table corresponds to a unit used in your module(s). The INST_ID and ID columns of the table specifies the unit’s identifier within the result set.

When displaying results of the Unused VCL Units profiler, the Details panel shows the list of units that import the unit selected in the Report panel. The data of the Details panel are exported to the UNUSED_VCL_UNITS_PROFILER_IMPORTING_UNITS table. Each record of this table corresponds to a unit that refers to this or that unit listed in the UNUSED_VCL_UNITS_PROFILER_SOURCE_FILES_DATA table. The PARENT_ID column contains the unit identifier (the same value that is stored in the ID column of the UNUSED_VCL_UNITS_PROFILER_SOURCE_FILES_DATA table).

The UNUSED_VCL_UNITS_PROFILER_IMPORTING_UNITS table does not contain the unit names. It has the COL_UNIT_INDEX column that specifies the index of the unit in the result set. Using this value you can retrieve the unit name from the UNUSED_VCL_UNITS_PROFILER_META_SOURCE_FILES table that contains information about all the analyzed units. The value stored in the COL_UNIT_INDEX column coincides with the value stored in the REC_ID column of the UNUSED_VCL_UNITS_PROFILER_META_SOURCE_FILES table.

Note: The ID and REC_ID columns of the UNUSED_VCL_UNITS_PROFILER_xxxx tables are not key columns. They may contain repetitive values. In queries you should use these values along with the INST_ID value (the result set identifier).

Below is detailed information about the tables.

The INSTANCES table

This table contains a list of exported result sets. Each result set is identified by the INST_ID value.

Table Field Name Description
CAPTION String. The caption of the exported result set.
COUNTER_DESCRIPTION Reserved.
COUNTER_FREQUENCY Reserved.
COUNTER_NAME Reserved.
INST_ID Integer. The identifier of a specific exported result set.

The UNUSED_VCL_UNITS_PROFILER_IMPORTING_UNITS table

This table stores information about units that imports the units mentioned in the UNUSED_VCL_UNITS_PROFILER_SOURCE_FILES_DATA table. Each row corresponds to a unit that imports this or that unit listed in the UNUSED_VCL_UNITS_PROFILER_SOURCE_FILES_DATA table. The data of the UNUSED_VCL_UNITS_PROFILER_IMPORTING_UNITS table are used to display information in the Details panel (see Unused VCL Units Profiler - Details Panel).

Table Field Name Description
COL_UNIT_INDEX Integer. The identifier of the unit. Using this identifier and the INST_ID value you can retrieve information about the unit from the UNUSED_VCL_UNITS_PROFILER_META_SOURCE_FILES table.
ID Integer. The identifier of the row within the result set.
INST_ID Integer. The identifier of the result set to which the row belongs. This is the same value as the result set’s INST_ID value in the INSTANCES table.
PARENT_ID Integer. Identifier of the unit, to which the given unit refers (the same value that is stored in the ID column of the UNUSED_VCL_UNITS_PROFILER_SOURCE_FILES_DATA table).
REC_ID Integer. Position of the row in the list of referring units.

The UNUSED_VCL_UNITS_PROFILER_META_SOURCE_FILES table

This table contains information about units that are used in the tested modules.

Table Field Name Description
COL_FILE_NAME String. The unit’s file name.
COL_SYMBOL_MONIKER String. Reserved.
ID Integer. The identifier of the row within the result set. This column together with the INST_ID column is used as the identifier of the unit within the result set.
INST_ID Integer. The identifier of the result set to which the row belongs. This is the same value as the result set’s INST_ID value in the INSTANCES table.
PARENT_ID Not used. Always contains -1.
REC_ID Integer. The zero-based identifier of the unit. This column together with the INST_ID column can be used as the identifier of the unit within the result set.

The UNUSED_VCL_UNITS_PROFILER_SOURCE_FILES_DATA table

This table stores the list of application units. Each row of this table corresponds to a unit. The data stored in this table corresponds to the data displayed in the Report panel (see Unused VCL Units Profiler - Report Panel).

Table Field Name Description
COL_IMPORTING_USER_UNITS Integer. The number of user units that refer to the given unit. This column stores the same value that is displayed in the Importing User Units column of the Report panel.
COL_FILE_NAME String. The name of the unit’s source file. This column stores the same value that is displayed in the Source File column of the Report panel.
COL_MODULE String. The name of the module that contains the unit. This column stores the same value that is displayed in the Module column of the Report panel.
COL_UNIT String. The name of the unit. This column stores the same value that is displayed in the Unit column of the Report panel.
COL_UNUSED Integer. Contains either 0, or -1. Specifies whether the unit is used in the analyzed module (0) or not (-1). The values stored in this column are used to display information in the Unused column of the Report panel.
ID Integer. The identifier of the row within the result set. This column together with the INST_ID column is used as the identifier of the unit within the result set.
INST_ID Integer. The identifier of the result set to which the row belongs. This is the same value as the result set’s INST_ID value in the INSTANCES table.
PARENT_ID Not used. Always contains -1.
REC_ID Integer. The zero-based identifier of the unit. This column together with the INST_ID column can be used as the identifier of the unit within the result set.

The RELATIONS table

This table contains information about parent-child relations between the database tables holding the results generated by the Unused VCL Units profiler.

Field Name Description
COL_CHILD_TABLE String. The name of a child table.
COL_PARENT_TABLE String. The name of a parent table. The NULL value means that the table specified by COL_CHILD_TABLE is a top-level table.
ID Integer. The identifier of a specific relation in the RELATIONS table.
INST_ID Integer. The identifier of the INSTANCES table item corresponding to the result set whose data the table contains.

See Also

Exporting Profiling Results to Database
Unused VCL Units Profiler - Overview
Unused VCL Units Profiler - Report Panel

Highlight search results