A datamart can be used to edit or select information.
Note that to use a datamart block, configuration in the general settings is required.
Drag a datamart block to the worksheet and connect it to one input block.
You can connect a datamart block to the following blocks:
- Webservice
- Upload
- Webhook
- Snapshot
You can use the datamart block only if the selection has been saved.
Double-click the datamart block to open its settings.
On the left side, choose the datamart you want to use. On the right, map the fields.
Editing data
Editing can be done by selecting the desired datamart from the dropdown.
Based on the datalayer options, the items in the field list can be selected (mapped). Use the ‘Automap fields’ button or drag the field from the right column to the corresponding field in the left column.
Additional options
Depending on the options selected in datalayers, you can apply the following actions:
- Upsert:
This option updates records in the underlying datastore, if the key is present. If it is not, a new record is created. - Delete:
This option deletes records in the underlying store, if the key is present - Merge:
This option compares the underlying datastore with the supplied data. Records that do not exist in the datastore are created, records that exist are updated, and records that are missing from the supplied data are removed from the datastore.
Advanced options
By default, a datamart retains the existing value of a field if you leave it blank while merging data.
With the ‘Show advanced options‘ feature, you can choose to empty the existing value if you supply an empty field. You do this by checking the ‘Show advanced option’ option and then choosing ‘Allow empty value’.
N.B.: The key should never be emptied, so the option is not given here.
Execute
Select the datamart block and right-click and then click ‘Execute’.
Note! When you delete the datamart in a flow, you never delete the data.
Select
All datamarts can be selected under source and can be used as a regular data source.