Excel parser settings
The mono- and multilingual Excel (and CSV) parsers have similar configuration attributes. For details, see the following sections:
Parser settings:
Row with header (
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.
First row with data (
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
firstdatarowonward.String ID columns (
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
Include Sheetname as part of String ID (
IdSheetname).Default:
false.Enable this setting to add the name of the worksheet to the string ID.
String ID postfixes (
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.nameandxyz.description, wherexyzis the ID listed inidColumns.Notes when this field is left empty:
1 column containing translatable texts: the
idas listed inidColumnswill be used as is.More than one column containing translatable texts: the parser will make the string IDs unique by adding 0, 1, 2,...
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
sourceColumnsandtargetColumnscan 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 7.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).
Source columns (
sourceColumns).Define the columns that contain the source texts (using the forms).
Target columns (
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
targetColumnsmust be the same assourceColumns. If not, then the parser will attempt to detect the columns from the header row.
Comment columns (
commentColumns).Define the columns that contain the comments.
Example 10.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
Max. length columns (
maxlenColumns).Define the maximum number of characters in the column.
Keep empty if there are no comments defined.
List the columns
Fallback columns (
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 11.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 character (CSV only) (
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.
For other parser settings, see the Generic parser settings article.