Online Documentation for Data Import for InterBase/Firebird
Configuration file format
The configuration file is divided into several sections.
[Connection]
This section contains parameters for connecting to the server: Host, Port, tunneling settings, Login, Password (encrypted). These parameters are obligatory.
[PREFERENCES]
This section contains the general settings of the utility.
ImportToViews
1 - enabled, 0 - disabled
The following sections are unique for each imported file and contain the appropriate postfix (FILE_00, FILE_01, FILE_02, etc.)
In these sections the import options for each particular file are stored.
[FILE_00]
In the main file section the following parameters are used:
Database (destination database name), Table (destination table), FileName (the source file name)
ImportType
Indicates the format of the source file: 0 stands for MS Excel, 1 for MS Access, 2 - DBF, 3 - TXT, 4 - CSV, 5 - XML, 6 - MS Excel 2007, 7 - MS Word 2007, 8 - HTML, 9 - XML Document, 10 - ODS, 11 - ODT
The next section is specific to the file format and is named correspondingly, e.g. [FILE_00_XLS]. In this section the following specific file type options are set:
[FILE_00_XLS]
SkipRows, SkipCols - the number of rows and columns in the source file to be skipped on import.
[FILE_00_Access]
SourceType
This option indicates the Access source type - Table or query, 0 stands for table, and 1 for query.
TableName and query - these options set the source Access table name to import from if source type is 0 and the source query text if the source type is 1.
[FILE_00_TXT]
SkipRows - the number of rows in the source file to be skipped on import.
[FILE_00_CSV]
SkipRows - the number of rows in the source file to be skipped on import.
CSVDelimiter, CSVRightQuot, CSVLeftQuot - these options are used on reading the source CSV file, they store options for delimiting columns and the quotation marks.
The next section is [FILE_XX_MAP].
It is also specific to the file type, but is obligatory for all file types. In this section correspondence between the source file columns and the destination table fields is set.
If the source file is an Excel file, then the map is set in the following format:
<DB_FieldName>=CellIndex.
Use semicolon to separate multiple cells. You can define an Excel row or column as a range of cells, e.g.
Field1=A1;A4;A6-A9;B1-F1.
If the source file is an Access or DBF file, then the mapping is set in the following format:
<DB_FieldName>=<Source_Field_Name>.
If the source file is a TXT file, the mapping looks in the following way:
<DB_FieldName>=<Position>;<Size>.
This means that you should provide the starting position and the size of the source file column for each destination field.
To set mapping for a CSV file, provide a column number for each destination field, e.g.
Field1=1
Field2=4
etc.
The properties that are set in sections [FILE_XX_BASE_FORMATS] and [FILE_XX_IMPORT_OPTIONS] correspond to those set on the 'Base Formats' and the 'Options' tabs.
The values that stand for BOOLEAN TRUE and BOOLEAN FALSE values are set in sections [FILE_XX_BOOLEAN_TRUE] and [FILE_XX_BOOLEAN_FALSE].
The NULL values are set in section [FILE_XX_NULL_VALUES]
Data formats that are set for each destination field separately are stored in sections named in the following way:
[FILE_XX_DATA_FORMATS_<FIELD_NAME>],
e.g. FILE_00_DATA_FORMATS_FIELD1.
The properties within these sections also correspond to the properties set on the 'Data Formats' tab of the Settings data formats step for each field.
[FILE_00_IMPORT_OPTIONS]
This section contains parameters that define import options specified on Steps 6-9 of the wizard.
CommitAfterDone
1 - enabled, 0 - disabled
CommitRecCount
The number of records in each block to be supplemented with the COMMIT statement.
ImportRecCount
1 - enabled, 0 - disabled
ImportAllRows
1 - enabled, 0 - disabled
SaveResultSQL
1 - enabled, 0 - disabled
ResultSQLFile
The path to the result *.sql file.
ImportKind
0 - Universal Mode, 1 - Native Mode
TruncateLongString
1 - enabled, 0 - disabled
RollbackIfError
1 - enabled, 0 - disabled
ImportMode
0 - Insert All, 1 - Insert New, 2 - Update, 3 - Update or Insert, 4 - Delete, 5 - Delete or Insert
ImportAddType
1 - enabled, 0 - disabled
AllowDuplicates
1 - enabled, 0 - disabled
NativeModeKind
0 - Single Commands, 1 - Batch insert
[#General#]
This section stores information about the product name and its major version.
See also: |