4D v15EXPORT STRUCTURE |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D v15
EXPORT STRUCTURE
|
EXPORT STRUCTURE ( xmlStructure ) | ||||||||
Parameter | Type | Description | ||||||
xmlStructure | Text variable |
![]() |
Exported XML definition of the 4D database structure | |||||
Originally introduced in 4D v14 R4
Theme: Structure Access
The new EXPORT STRUCTURE command exports in xmlStructure the current 4D database structure definition in XML format. This command uses the same mechanisms as the Export > Structure definition to XML file... menu command which is available in the 4D Design mode interface (see Exporting and importing structure definitions).
In xmlStructure, you pass a text variable to be filled with the structure definition. The exported definition includes tables, fields, indexes and relations, along with their attributes and the various characteristics that are necessary for a complete definition of the structure. Invisible elements are exported and tagged with appropriate attributes. Removed elements, however, are not exported.
The internal “grammar” of 4D structure definitions is documented through DTD files — also used for the validation of XML files.The DTD files used by 4D are grouped together in the DTD folder, located next to the 4D application. The base_core.dtd and common.dtd files are used for the definition of the structure. For more information about 4D structure definitions, feel free to consult these files, as well as the comments they contain.
You want to export the current database structure in a text file:
C_TEXT($vTStruc)
EXPORT STRUCTURE($vTStruc)
TEXT TO DOCUMENT("myStructure.xml";$vTStruc)
Product: 4D
Theme: Language
Number:
705086
4D v15 - Upgrade (standard edition) ( 4D v15)