Notes on creating a new Exemplar X-reference or Exemplar template file.

PETROG uses two files to create an Exemplar-format export:
1) a text copy of the Exemplar template, which is read by PETROG then re-written with the appropriate columns completed;
2) a cross-reference file linking the definitions of Exemplar items to their equivalents in PETROG.

The former is stored on the PETROG templates directory:
templates\Exemplar.xlt
and the latter is stored as a Paradox database table:
PetrogDB\ExemXref.db

We want to use Excel to edit the cross-reference file, because Paradox does not allow easy editing, and to use Paradox to store the data, because it is a stable file format. However, Excel and Paradox conspire to make it non-trivial to import a file into Paradox.

Before leaving Excel, ensure that there are no commas in text fields (such as "Mica, undifferentiated", which should be changed to "Mica (Undifferentiated)"). These edits must be made identically in the file being edited and in
templates\Exemplar.xlt
Once edited, the Excel file should be saved as tab-delimited text and this file used to import into Paradox. Both the Excel file and the text file are intermediate forms which need not be retained.


