--- title: "Mapping – Records and paths" slug: "intro-profiles-phase-3-records-paths" updated: 2026-09-29T11:30:21Z published: 2026-09-29T11:30:21Z canonical: "docs.lobstersoftware.com/intro-profiles-phase-3-records-paths" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.lobstersoftware.com/llms.txt > Use this file to discover all available pages before exploring further. # Mapping – Records and paths Starting from the Source tree, we have two crucial design mechanisms. ## Records The first design mechanism is implicit and simply given by the records themselves. The target structure is traversed once per record of the source tree. This determines the structure of the target data at the highest level. Each (partial) source tree of a record on the source side thus always generates a record with a (partial) Target tree on the target side. More abstractly, the records order repeating structures of the input data on the top-level. How this is done, is determined by the respective parser rules (see [When does the parser start a new record?](/v1/docs/en/intro-profiles-phase-2-parsing-new-record)) and how you built your source structure. You have already seen a simple example (see [Parsing](/v1/docs/en/intro-profiles-phase-2-parsing)). ## Paths The second design mechanism is used in the records on the target side. When generating the source tree from the source structure and the input data, a node of the source structure in a record can be generated multiple times. As we mentioned above, each (partial) source tree of a record on the source side always generates exactly one record with a (partial) target tree on the target side. However, repeat structures (nodes occurring multiple times) within the source tree are not transferred directly to the target tree! By default, only the first node is transferred! You must explicitly initiate a repetition of a node in the target tree by giving that node in the target structure a path. This is done by setting the target structure node attribute "Path". Specifically, you set the path of a node of the target structure to a node of the source structure. The node in the target tree is then repeated exactly as often as the node in the source tree to which the path is set. ### Example That sounds a bit complicated at first, but basically, it is very simple. Let us look at the slightly modified source structure (and almost identical target structure) of the previous example and slightly adapted input data. ![images/download/attachments/201684048/777-version-1-modificationdate-1749438061223-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/777-version-1-modificationdate-1749438061223-api-v2.png) ```plaintext ADR;Randy;Random;Mainstreet 1 TEL;00498157488364 TEL;00491723374222 ADR;Sharon;Fillerup;Treeway 3 TEL;00498157483221 ``` If everything works as we want, then we get the same number of records as in the first example (see [Parsing](/v1/docs/en/intro-profiles-phase-2-parsing)), but we should get two nodes `phone_number_in` in the first record. Let us take a look at the result of a Mapping test with the above input data. ![images/download/attachments/201684048/778-version-1-modificationdate-1749438061194-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/778-version-1-modificationdate-1749438061194-api-v2.png) As you can see, it works in the source structure, but in the target structure, we only get one node `phone_number_out`. And the reason for this is, as you may already suspect, that we have not set a path from the node `phone_number_out` to the node `phone_number_in`. We now do that in the attribute **Path** of the target node `phone_number_out`. Enter the value `phone_number_in` there. We review the result in the mapping test and see that we now have what we wanted. The twice repeated node `phone_number_in` from the source tree now causes the node `phone_number_out` in the target tree to repeat twice as well. ![images/download/attachments/201684048/780-version-1-modificationdate-1749438061192-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/780-version-1-modificationdate-1749438061192-api-v2.png) ## Summary ![images/download/attachments/201684048/Datenblatt_Pfad_EN-version-1-modificationdate-1749438061199-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/Datenblatt_Pfad_EN-version-1-modificationdate-1749438061199-api-v2.png) So you have two mechanisms to model repeating parts of the input data on the way to your output data. First, the splitting into records during parsing and then the setting of paths to model repeated data within a record (e.g. the multiple occurrences of "node X" in the diagram above). In our concrete example, we first split our input data into addresses (one address per record). Then we used a path from our telephone number node in the target structure to the telephone number node in the source structure to make sure the target structure node will be repeated as often in target tree as the source structure node in the source tree. The next step is the filling of a record of the target tree. Structured representation of the input data in Phase 2. The source tree is generated by parsing the input file and forms the basis for the mapping in Phase 3. Structured representation of the input data in Phase 3. The target tree receives the values transferred via mapping and passes them on to Phase 4, Phase 5, or Phase 6. The core task of Phase 3. Mapping transfers data from the source structure to the target structure according to defined rules. In the process, fields can be transformed, functions can be called, and values can be calculated.