Versions Compared
Key
- This line was added.
- This line was removed.
- Formatting was changed.
You can use a Text file to define the structure of your Source or Destination layout. To create a Text file layout, you need to specify the format of the text file.
Follow the steps below to create a text layout using the default option:
- Click Configure > LAYOUTS > Text.
- Click Create Text Layout.
- On the Create Layout screen, select the Default option from the Select Layout UI Type field.
- Click Next.
- On the Create Layout screen,
- In the Name and Description fields, type the name and description of the new text layout.
Name: Only alphanumeric and underscore are allowed and you must start the layout name with an alphabet or underscore.
Description: Only alphanumeric and few special characters(_ - . : , @ $ ? \\ and space) are allowed and you must start the description with an Alphabet/Underscore/Number. - Select the Data Header Present check box if the data header is present in the text file. Data Header usually contains the titles of the fields in a text file.
- In the Record Separator field, provide the record separator, for example, \n for newline or " " for space. The record separator is used to separate the records.
- In the Field Separator field, provide the field separator, for example, \t for Tab or " " for space. Field Separator is used to separate fields.
- In the Definition Mode field, select either Import Definition File or Enter the Fields Sequentially option.
To define the layout using the Import Definition File option, follow the steps below:- In the Definition File field field, select the definition type from the drop-down list and click and click Upload File, navigate to the required file, and click Open to upload the file.
In the Field Name field, enter the name of each field.
In the Type field, select the type of data.
Following are the options - string, number, and date. If the data type is Date, select the format of date and time from the in the Date Format and Time Format drop-down listsFormat fields.Info To insert rows, specify the number and position of the rows to be added in the Number of Rows and at Position and click Add Row. You can add a maximum of 99 rows at a time.
To remove rows, specify the number and position of the rows to be deleted in the Number of Rows and at Position and click Remove Row.
- In the Definition File field field, select the definition type from the drop-down list and click and click Upload File, navigate to the required file, and click Open to upload the file.
- Expand the Advanced Properties.
- In the Character Set Encoding field, enter the required character set encoding.
- Dynamic Header Support check box is an advanced feature of Text layout, which is used to parse an excel or text file, if:
FieldNames defined in the source layout and the Data Headers (Column Name) of the excel/text file are same but not in the same order.
FieldNames defined in the source layout and the Headers of the excel/text file are not same. They may or may not be in the same order.
If the headers are not matched between Layout Definition and Source File then XML (output of schema) will only have Root rather than any Record entry. For instance, if the headers of the source layout are Id, Name, and Age and the headers of the data file are Emp Id, Emp Name, and Emp Age then the output of the layout will be blank. - On selecting the Dynamic Header Support check box, Allow Ignore case, and Allow More Fields check boxes appear.
- Select Allow Ignore case to ignore the case mismatches in the header of the layout and the data file.
- Select Allow More Fields for adding an additional field dynamically in the header row of the file when needed.
- Select Quotes Handling On check box to enable quotes handling.
- When using Text layout at the target side, select the to enclose the target field values in double quotes. For example, "John","Smith".
Select Allow Less Fields check box to process the data in case the number of fields in the data file is less than the number of fields defined in the layout.
Note When the number of fields in the data file is less than the number of fields defined in the layout then layout will not process the data and give an error during execution.
- When you select the Allow Less Field check box then layout generates an empty tag for fields that are not present in the data file.
- This option is applicable only when you use the layout at the source end.
Select Remove Last New Line Record Separator check box if you want to remove the new line record separator from the target file.
- In case the input data contains some characters that are invalid in XML then this may result in the aborted mapping. You can filter these invalid XML characters by selecting the Filter Invalid XML Characters check box.
- Type the row start position in the Row Start Position textbox. Row Start Position specifies which row of the text file is counted as first row.
For example, if you enter value as 5 in the Row Start Position, 5th row of the text file is counted as the first row. If this layout is used at source end, the data from the 5th row onward is taken for processing. - In case, you want to skip certain bottom row from the text file then define the row count from Bottom Row Skip Count field.
- Type the enclosing characters to remove from the data file while parsing in the Handle Enclosing Character. Currently, following enclosing characters are supported:
- Single Quote (')
- Double Quote (")
- Less than symbol (<)
- Greater than symbol (>)
Tip Handling Enclosing Character is supported for source schema only. If Quotes Handling is checked true, the value of data file at the target schema will be appended with the enclosing character. - In the Project field, select the project.
- Click Save.
- In the Name and Description fields, type the name and description of the new text layout.
Panel | ||||
---|---|---|---|---|
| ||||
What's newBest practicesTraining guidesFrequently asked questionsAdeptia Connect APIsAdeptia security report |