Skip to content

DF_FILE_REVISION

See Also: Get_Attribute, Set_Attribute, Structure_Start

Returns the revision of the table.

Level

Table

Supported by

All Drivers

Type

String, permanent

Access

Read Only

Values

A string containing the version of the table.

Remarks

The attribute holds the table’s revision.

The DataFlex Pervasive.SQL Driver returns the version of Pervasive.SQL.

The DataFlex SQL Drivers return the database name plus its version. For example:

MSSQL_DRV: Microsoft SQL Server 15.00.2080
ODBC_DRV: MySQL 8.0.15
ODBC_DRV: MariaDB 10.04.000013

The Embedded Database supports three table revisions: 2.3, 3.0, and 4.0. When a table is opened, its revision is checked, and if the revision is not supported, the table is not opened, and an error (DFERR_DATA_FILE_NOT_COMPATIBLE) is generated.

Revision Capabilities

Revision Capabilities
2.3 Support for ASCII, Numeric, Date, and Overlap* columns
Support for 10 indices that can hold 6 segments each
DataFlex 2.3
3.0 Same as 2.3 with additional features:
Support for text and binary columns
Support for 15 indices that can hold 16 segments each
Support for header integrity checking
Support for restructuring tables by improved tools/API
DataFlex 3.0
4.0 Same as 3.0.
A table will change to version 4.0 if one (or more) of its columns relate to another table with a number higher than 255. If the table’s definition is adjusted so that there are no more columns that relate to tables with a number above 255, the revision will fall back to 3.0.
DataFlex 7 and DataFlex 3.2 (character mode)

When the definition of a table with revision 2.3 is changed, it will be saved as (at least) a 3.0 table. After this, the table cannot be opened by 2.3 DataFlex applications. Revision 4.0 tables cannot be opened by versions of DataFlex prior to 7 and versions of DataFlex (character mode) prior to 3.2.

Example Procedure

The sample procedure below shows the revision of every table in the file list.

Procedure ShowRevision
    Handle hTable
    String sTable
    String sRevision

    Move 0 To hTable
    Repeat
        Get_Attribute DF_FILE_NEXT_USED Of hTable To hTable
        If (hTable > 0) Begin
            Open hTable
            Get_Attribute DF_FILE_LOGICAL_NAME Of hTable To sTable
            Get_Attribute DF_FILE_REVISION Of hTable To sRevision
            Showln sTable " -- " sRevision
            Close hTable
        End
    Until (hTable = 0)
End_Procedure // ShowRevision

Note

  • Overlap columns were replaced by multi-segment relationships in DataFlex 11.0 and are obsolete.