This function works the same way as LookupValue but in case nothing is found it will create the missing record. This is useful for integration and ETL projects where you can simplify the data import scripts.
Unique identifier (Guid) of lookup model element
|parameterValue||Value to lookup by (that the lookup's data structure will use as a filter parameter).|
|createParameters||Key-value pairs providing data for a new record (in case it does not exist).|
This function uses the ListDataStructure entity of the lookup for creating the record. For this you will need to set AllFields to
True so the data will be safely inserted to the database. This is mandatory. Primary key and other system fields (creation time and user) will be filled in automatically.
You should use this function carefully as it writes data during transformations. Especially be careful when state-machines exist on the entity being written to. For a sake of simplicity you should mainly use this function for inserting missing records into simple lists e.g. while importing data from external data sources.