Skip to content

Commit f64efeb

Browse files
Update data-importer-extension.md
New feature - Mapping parameter is supported by DI + IM, which can be used to create associations while importing data from excel and csv.
1 parent 4daa464 commit f64efeb

1 file changed

Lines changed: 21 additions & 1 deletion

File tree

content/en/docs/appstore/use-content/platform-supported-content/modules/data-importer-extension.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,15 @@ The Data Importer document as a source for import mapping is available from [Stu
2222

2323
### Typical Use Cases
2424

25-
The Data Importer extension allows you to import data from Excel and CSV files directly into your app. You can create a Data Importer document to define which columns to import and an NPE to hold the imported data, along with source-to-target mapping.
25+
The Data Importer extension allows you to import data from Excel and CSV files directly into your app. You can create a Data Importer document to define which columns to import and an NPE to hold the imported data, along with source-to-target mapping.
26+
Data Importer document can also be used as a source for creating Import Mapping and you can leverage the capabilities provided by Import Mapping to import data into existing Entity.
2627

2728
### Features {#features}
2829

2930
This extension supports following source files:
3031

3132
* Microsoft Excel (*.xls, .xlsx, .csv*)
33+
* Mapping Parameter support is extended for Data Importer document with Import Mapping.
3234

3335
### Limitations
3436

@@ -266,6 +268,24 @@ The instructions below show how to import data from an Excel (or CSV) file.
266268

267269
{{< figure src="/attachments/appstore/platform-supported-content/modules/data-importer-extension/import-with-mapping-params.png" class="no-border" width="500" >}}
268270

271+
### Support for Mapping Parameter in Import Mapping {#mapping-param-import-mapping}
272+
273+
Mapping Parameter (https://docs.mendix.com/refguide/import-mappings/#mapping-parameter) is now supported by Data Importer starting with Mx 10.21. Mapping Parameter can be used to create associations with imported data. Primitive types are not supported but any Mx object type can now be passed as *Mapping Parameter*.
274+
275+
The instructions below show how to define *Import Mapping* with mapping parameters.
276+
277+
1. In your **Import Mapping**, drag an Entity from the *Connector* tab and drop into the target object placeholder. Click **Cancel** on the **Map entity...** dialog as we will fill in the details later.
278+
2. Similarly, drag another Entity from the *Connector* tab which you intend to pass as a parameter & drop into parameter placeholder.
279+
3. **Double Click** on source or target object to open the **Map entity...** dialog.
280+
4. Select **Call a microflow** to **Obtain Mendix Object** for your Import Mapping.
281+
5. If not already present, create a *Microflow* which will create an Object of target Entity and set association with the passed parameter.
282+
6. In your **Import Mapping** you can choose the **Set association** to **Yes** and select a valid *Association* from the dropdown.
283+
7. Click on **Map attributes** to map the source schema value elements to target Entity attribute.
284+
285+
The resultant Import Mapping should look like below.
286+
287+
{{< figure src="/attachments/appstore/platform-supported-content/modules/data-importer-extension/IM-with-mapping-param-association.png" class="no-border" width="500" >}}
288+
269289
### Before Running Your App {#data-import-with-mapping-app}
270290

271291
Before you can run your app, do the following:

0 commit comments

Comments
 (0)