> For the complete documentation index, see [llms.txt](https://community-test.logicnets.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://community-test.logicnets.com/release-9/platform-documentation/process-node-parts/extract-data-objects-from-data-log.md).

# Extract Data Objects from Data Log

## Description

In LogicNets, *context* is session memory that contains all data objects that can be managed by the logicnet in an application. The *data log* is the meta-data structure inside the session that contains meta data about the data-objects in the context. This part allows you to update the session context based on entries in a specified data-log variable (collection). It works hand-in-hand with the [*Generate Data-Log*](/release-9/platform-documentation/process-node-parts/generate-data-log.md) part you use to generate a data-log variable.

Note: In the LogicNets Designer this process step is displayed with the label *generate\_ctx\_from\_log.*

**Data Log Example**

```
log = {
    ['mypath'] = {
        path = 'mypath'
        value = 1,
        data_type = 'number'
    },
    ['mypath2'] = {
        path = 'mypath2'
        value = { “a”, “b” },
        data_type = 'number'
    }
}
```

**Node Type:** This part is located in the *Misc* dropdown menu in the Process node.

**Used With:** You can use this part with all framework and non-framework projects.

## Additional Details

Not all values present in the context are also in the data log.

* By default the system only puts into the data log the values collected by a UI part, such as text-input, radio, dropdown, and checklist.
* Some parts, such as *Set Data Object*, have an additional *Add to Log* part parameter to add the process value to the data log.

The indexes in a data-log collection can be represented as either alphanumeric (typical) or numeric. If the index is alphanumeric the index should be equal to the path value of the data-log entry.

The system uses the data type to ensure the value is set correctly. This conversion is required, because a data log may be serialized into an XML message and the value type is lost during this serialization. For example:

* The value is converted to a number when the value in the data log is a string but the data type is a number.
* The first value is written into the context when the value in the data log is a collection but the data type is a string.

You can also use this part to **normalize log**, forcing the indexes to be alphanumeric and the value types to be based on the data type.

## Editor Fields

Configure this part using the following fields:

| Field Name                     | Description/Use                                                                                                                                                                                                                                                                                                                                                                                                  | Type/Option | Optional/Mandatory |
| ------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------- | ------------------ |
| Mode                           | <p>The part behaves differently based on the mode you select.<br><strong>Merge log values into context:</strong> The system merges the value in the given data log into the given context and correct the value type if needed.<br><strong>Normalize log:</strong> The system normalizes the given data log:<br>- Indexes are equal to the data-log-path<br>- Value types are updated based on the data-type</p> | Dropdown    | Mandatory          |
| Context data-object            | For *Merge log values into context*, this is the location where the system writes the values in the data log.                                                                                                                                                                                                                                                                                                    | Object      | Mandatory          |
| Merge with context data-object | For *Merge log values into context*, the system clears the context data object before exporting the data log if this dropdown is set to *No*.                                                                                                                                                                                                                                                                    | Dropdown    | Optional           |
| Log data-object                | This is the location of the input data log.                                                                                                                                                                                                                                                                                                                                                                      | Collection  | Mandatory          |
| Result Log data-object         | For Normalize log, this is the location where the system stores the normalized datalog.                                                                                                                                                                                                                                                                                                                          | Collection  | Mandatory          |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://community-test.logicnets.com/release-9/platform-documentation/process-node-parts/extract-data-objects-from-data-log.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
