Double-click tFileInputMSDelimited to
open the Multi Schema Editor.
- Click Browse... next to the File name field to locate the multi schema delimited file you need to process.
In the File Settings area:
-Select from the list the encoding type the source file is encoded in. This setting is meant to ensure encoding consistency throughout all input and output files.-Select the field and row separators used in the source file.Note:
Select the Use Multiple Separator check box and define the fields that follow accordingly if different field separators are used to separate schemas in the source file.A preview of the source file data displays automatically in the Preview panel.Note:
Column 0 that usually holds the record type indicator is selected by default. However, you can select the check box of any of the other columns to define it as a primary key.
Click Fetch Codes to the right of the
Preview panel to list the type of
schema and records you have in the source file. In this scenario, the source
file has three schema types (A, B, C).
Click each schema type in the Fetch Codes panel to display its data structure below the Preview panel.
Click in the name cells and set column names for each of the selected
In this scenario, column names read as the following:-Schema A: Type, DiscName, Author, Date,-Schema B: Type, SongName,-Schema C: Type, LibraryName.You need now to set the primary key from the incoming data to insure its unicity (DiscName in this scenario). To do that:
- In the Fetch Codes panel, select the schema holding the column you want to set as the primary key (schema A in this scenario) to display its data structure.
Click in the Key cell that corresponds to the
DiscName column and select the check box that
Click anywhere in the editor and the false in the
Key cell will become
You need now to declare the parent schema by which you want to group the other "children" schemas (DiscName in this scenario). To do that:
In the Fetch Codes panel, select schema
B and click the right arrow button to move it to
the right. Then, do the same with schema C.
The Cardinality field is not compulsory. It helps you to define the number (or range) of fields in "children" schemas attached to the parent schema. However, if you set the wrong number or range and try to execute the Job, an error message will display.
In the [Multi Schema Editor], click
OK to validate all the changes you did
and close the editor.
The three defined schemas along with the corresponding record types and field separators display automatically in the Basic settings view of tFileInputMSDelimited.The three schemas you defined in the [Multi Schema Editor] are automatically passed to the three tLogRow components.
If needed, click the Edit schema button
in the Basic settings view of each of the
tLogRow components to view the input
and output data structures you defined in the Multi
Schema Editor or to modify them.