Excel parser settings
The mono- and multilingual Excel (and CSV) parsers have similar configuration attributes. For details, see the following sections:
Parser settings
headerrow
.This number (0, 1, 2, ...) indicates the row that contains the header information.
Typically, the header is on the top row (i.e., 1).
Set to 0 if there is no header row.
firstdatarow
.This number (1,2,3,...) indicates the first row that contains data. If an Excel file has one header row, then the data row typically starts at 2.
The parser will parse all rows from the
firstdatarow
onward.idColumns
.The Excel file usually contains one or more columns (A, B, C) that contain the ID information (
idColumns
).If, for example, columns B and C contain the article category and number, then enter the following lines:
B C
In some cases, the ID is a unique text. In those cases, we recommend that you hash the text so that the resulting ID always contains valid characters. Use, for example, the following when the ID is composed of 2 columns, B and C, and C must be hashed:
B C hash
idNames
.A row that has one string ID (using
idColumns
) can have multiple columns containing text.It is possible to define a unique postfix. If there are 2 columns, called 'name', and 'description', define the following:
name description
The resulting string IDs are then
xyz.name
andxyz.description
, wherexyz
is the ID listed inidColumns
.Notes when this field is left empty:
1 column containing translatable texts: the
id
as listed inidColumns
will be used as is.More than one column containing translatable texts: the parser will make the string IDs unique by adding 0, 1, 2,...
IdSheetname
.Enable this setting to add the name of the worksheet to the string ID.
Source and target columns (6 forms).
An Excel file contains source and target pairs. For example, the source name and descriptions are in columns B and C, and the target name and descriptions are in columns D and E. In that case, the fields for
sourceColumns
andtargetColumns
can be defined asB C
and
D E
Not all Excel files have such a nice static definition. In many cases, the actual columns must be determined from the header row.
The Excel parser supports various forms of line definition.
Table 4.Form
Example
Description
1
Empty
Search the column by the locale name in the header row (de-DE, de_DE, de, ...).
2
C
Single character. This means column C (2).
3
de-DE A
de-DE is in column A.
4
de-DE GERMAN
de-DE is in the column whose header matches GERMAN (case-insensitive).
5
de-DE ~XYZ
de-DE is in the column that has XYZ in the header (case-insensitive).
6
de-DE #2
de-DE is in the column that has the 2nd occurrence of de-DE in the header (case-insensitive).
sourceColumns
.Define the columns that contain the source texts (using the forms).
targetColumns
.Define the columns that contain the translations (using the forms).
One column containing source/target texts.
If the source texts must be overwritten, then use the same column definitions as
sourceColumns
.The number of source and target columns must be the same
The number of lines for the
targetColumns
must be the same assourceColumns
. If not, then the parser will attempt to detect the columns from the header row.
commentColumns
.Define the columns that contain the comments.
Example 4.There are 3 source columns: B, C, D, and E, where B and D have the same comment in column F, C has no comment, and E has the comment in G:
Source columns:
B C D E
Comment columns:
F - F G
emptysourceFallbackColumns
.Keep this setting empty to preserve empty source strings. In that case, the translator could change the translation.
If this setting is the same as
sourceColumns
, empty source strings will be skipped.Use the fallback to handle empty source texts. If the source text is empty, the fallback column will be used.
The 6 forms can be used as specified for the source and target columns.
Example 5.There are 2 source columns: B and C.
If B is empty, then D must be used.
If C is empty, then no fallback is available.
Source columns:
B C
Empty source fallback columns:
D -
separator
.This setting is only used for CSV files. Most CSV files are comma-separated. Other characters such as ';' or '\t' for tabs would be possible.