CSV file format to import mappings in extension mapping documents
You can define mappings in extension mapping documents in a comma-separated value (CSV) file, which you can then import into the catalog.
Purpose
Use a CSV file to define and import extract, transform, and load (ETL) transactions that occur outside of IBM® InfoSphere® Information Server.
Syntax
The following syntax rules govern how to correctly define applications, stored procedure definitions, or files in the extension mapping document in CSV format.
- Column Headings
- The following column headings are required and must be in the
first row of the extension mapping document. The headings are:
- Source Columns
- Target Columns
- Rule
- Function
- Specification Description
- Source Columns, Target Columns
- If the context of an asset is not in the catalog, that mapping is not imported into the catalog.
- Rule
- Text that describes the purpose or business reason of the mapping. For example, a rule might be Removes duplicate subscribers from billing list.
- Function
- Text that describes what the mapping does. For example, a function might be Compares subscriber names in 2 tables.
- Specification Description
- Text that describes the movement of data, the process in which this movement takes place, or additional information.
- Custom attribute columns
- The name of the custom attribute is the column heading. The name must be at least one alphanumeric character in length and must be unique. The name must not contain quotation marks (") or single quotation marks (').
- Special characters and language support
- Commas
- A comma (,) is the only accepted delimiter.
- Quotation marks
- The use and treatment of quotation marks (") vary according to
the column.
Table 1. Use or treatment of quotation marks according to column Column Use or treatment of quotation marks - Source Columns
- Target Columns
Quotation marks are removed during import. - Rule
- Function
If quotation marks occur in the text, they must be enclosed within quotation marks (" " "). - Specification Description
Quotation marks are required around the entire text of the field if the text includes non-alphanumeric characters, such as mathematical symbols or commas. - Language support
- The CSV file must be in UTF-8 or in ANSI encoding to be compatible with all languages.
Example
You need to create a CSV file to import extension mappings into the catalog. The following example shows how a CSV file might look. The import file has 4 mapping rows that show variations of name, source assets, and target assets. All assets that are listed in the Source Columns and in the Target Columns exist in the catalog. Custom attributes are listed in alphabetical order after the Specification Description column.
Name | Source Columns | Target Columns | Rule | Function | Specification Description | CA_free_text | CA__mult_values |
---|---|---|---|---|---|---|---|
!@#$% | NewApp_1 | NewApp_2 | This is a rule | Mapping name with special characters | |||
simple name | NewApp_3, NewApp_4 | NewApp_6 | "Mapping with multi-value custom attribute, multiple sources to single target" | ["ca 1";"ca 2"] | |||
NewApp_8 | NewApp_5, NewApp_7 | Single source to multiple targets | This is a sentence in free text. | ||||
NoTarget | NewApp_9 | getdate (today) |