pfx-excel:unmarshal
Transforms the given Excel file into internal structure.
Properties
Option | Type | Default | Description |
---|---|---|---|
| Boolean | true | Indicates whether input contains a header record (must be on the first row). |
| string | Â | List of headers from the input which should be present in the output. |
| integer | 0 | Index of the sheet with the required data. |
| string | Â | Name of the sheet with the required data. If filled, it has precedence over |
| Boolean | false | Determines whether to skip the header record in the output. |
Examples
Transform Excel file into internal representation (default)
The default configuration expects that the data resides in the first sheet (index 0) and contains a header row. The format of the input is automatically determined based on the structure. XLS/XLSX formats are supported.Â
Input:
Route:
<to uri="pfx-excel:unmarshal"/>
Â
Output:
[[sku: 'sku', name: 'name'], [sku: '10', name: 'BMW'], ["sku": '20', "name": "AUDI"]]
Â
Transform Excel file into internal representation (without header)
Input:
Route:
<to uri="pfx-excel:unmarshal?header=sku,name&hasHeaderRecord=false"/>
Â
Output:
IntegrationManager version 5.8.0