---
sourceDocument: Brazil Customer Success Management
sourceDocumentLink: https://www.servicenow.com/docs/r/acct-lifecycle-events

 Release :

    - brazil

ft:locale :

    - en-US

ft:publication_title :

    - Brazil Customer Success Management

ft:clusterId :

    - actle

bundleId :

    - actle

workflow :

    - Customer and Industry


---

# Configure the Context Engine Mapper

# Configure the Context Engine Mapper {#ariaid-title1}

Release version: Brazil  
Updated September 10, 2026  
![](https://www.servicenow.com/docs/portal-asset/ico-clock) 3 minutes to read
Summarize  
![AI sparkle icon](https://servicenow.com/docs/portal-asset/ai-sparkle-icon) Summarized using AI  
This content was generated using new OpenAI-powered functionality. Results are provided on an as is basis and are not guaranteed to be accurate or complete.  

## Summary of Configure the Context Engine Mapper

The Context Engine Mapper in ServiceNow is a framework designed to map source entities to their corresponding context entities.
It allows you to specify which record in the context table applies to a data source, enabling context-specific data resolution such as linking engagements to customer accounts.
This mapping organizes and categorizes data collected by the Data Context Engine using breakdown fields like account type or engagement status.
Show full answer Show less  

## Key Features

* **Mapping Types:**
  * **Global (Related Table):** Matches source field values to query fields in a related table to return mapped context records.
  * **Metric Based:** Provides advanced, granular mapping logic depending on the data source used for metrics or measurements, offering enhanced filtering and flexibility.
  * **Script Based:** Overrides table-based mapping; scripts use source field values to determine context records when dot walking is not feasible.
* **Configurable Fields:** You select the source table and field, supporting related table and query field, resolving context table and field, and optionally apply resolving table conditions to filter results.
* **Script Option:** When complex logic is needed to resolve context, a script can be defined that returns context record IDs, overriding certain other mapping configurations.

## How to Configure

* Login with the role `snacctlc.customersuccessagent`.
* Navigate to **All \> Data Context Engine \> Context Engine Mappers \> Create New**.
* Fill in required details including mapping type, source and related tables, fields, and optionally scripts or conditions.
* Submit to save the mapper configuration.
* Publish the associated data source under **All \> Data Context Engine \> Data Sources** to start data collection and context record creation.

## What to Expect

Once configured and published, data will be collected on schedule, and context engine data records will be created and stored in the Context Engine Data table. This setup ensures data collected by the Data Context Engine is accurately categorized and mapped to the appropriate context records, supporting better data analysis and insights related to customer accounts, engagements, or other entities.  
After you have defined the data source, use the Context Engine Mapper to specify the record in the context table for which it is applicable.

The Context Engine Mapper is a framework that establishes mappings between source entities and their corresponding context entities. It enables the resolution of context-specific records based on given sources, such as resolving engagements from customer accounts.

You can use the Context Engine Mapper to determine which fields will be used to categorize data collected by the [Data Context Engine](https://www.servicenow.com/docs/31sCo3_pNilU3h3yb94iVw "The Data Context Engine aggregates data from multiple sources—both internal and external—collecting it in one place to support configuration decisions based on aggregated data ."). This mapping ensures that data is organized and analyzed based on designated breakdown fields such as account type, engagement status, or sold products.  
Note:  
You can set up the context engine to map the source and target tables using one of the following methods:

* Related table: Use the mapping rule `related table[query_field] = source table[source_field]`. In every record in the Source table, the Source field value is matched with the Query field in the Related table.
* Script: If a script is defined, it takes precedence over the table based mapping. The script checks the Source Field and the ID of the record to determine the appropriate context based on the resolving context table.
* Metric based: Mapping logic can vary depending on the data source used for metrics and measurements. Can be used for more granular and context specific mappings.
{#account-lifecycle-define-context-engine-mapper__ul_fzb_h2b_b2c}  
1. Login as a user with the `sn_acct_lc.customer_success_agent` role.
2. Navigate to AllData Context EngineContext Engine MappersCreate New.
3. Enter the following details:{#account-lifecycle-define-context-engine-mapper__table_oxx_g3l_ydc__entry__2}

   | Field | Description |
   |-|-|
   | Type | This can be: * Global: For each record in the source table, the source field value is matched against the query field in the supporting related table. If a match is found, the associated values from the resolving context field are returned as mapped context records. * Metric based: This type is used to enable mapping specific to certain data sources or conditions. The mapping logic can vary depending on the data source used and provides enhanced filtering and flexibility. {#account-lifecycle-define-context-engine-mapper__ul_tbl_ccn_vfc} |
   | Source table | Select the source table to which the data source is to be mapped. This table is related to the attribute selected in the Breakdown field in the Data Source table. For example, if you selected Account in the Breakdown field, select the Customer Account table here. |
   | Source field | The specific field in the source table that contains the data to be mapped. |
   | Supporting related table | The related table that will be used to connect the source and context tables. |
   | Query field | Select the field that is used to query or dot walk the Supporting related table to map data from the Source table to the Context table. |
   | Metric list | If Type is Metric based, select a data source from the list. If a data source listed here is used for a specific source or target table, this mapping takes precedence over the Global mapping. |
   | Resolving context table | The target table where resolved context records are stored. |
   | Resolving context field | The target field where the mapped data will be stored. |
   | Resolving table conditions (Optional) | You can use additional conditions, such as field level filters, to narrow down the results from the resolving context table based on specific criteria. |
   | Script | If you cannot query the context table through dot walking, you can define a script that uses the Source field and returns an array of possible context fields. |
   [ ]

   {#account-lifecycle-define-context-engine-mapper__table_oxx_g3l_ydc}  
   Note:  
   If a script is defined for a Metric based mapper, it overrides:
   * Supporting related table
   * Resolving table conditions

   {#account-lifecycle-define-context-engine-mapper__ul_vkz_fdf_yfc}

   The script returns an array of context record IDs based on the conditions defined.
4. Select Submit to save the context mapping.
5. Navigate to AllData Context EngineData Sources.  

   <br />

6. Open the data source you had created earlier and select Publish.

   Data will now be collected according to the defined schedule and the context engine data record is created and stored in the
   Context Engine Data table.
{#account-lifecycle-define-context-engine-mapper__ol_ehj_3gl_ydc}  
The following examples show how to set up the different types of mapping:

Related table (Global)
:

    <br />


Metric Based Type
:

Script
:

    <br />


*[\>]: and then


