---
schema_version: "1"
id: 83eed26f575ee38a13b3b7e97137f0af2c1e23215af17ece75049310760deb33
title: Prefill Assessment Questions with Previously Submitted Responses in a Discovery Framework Omniscript
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/ind/264-0-0/discovery_framework_prefill_questions.md
canonical_url: https://help.salesforce.com/s/articleView?id=ind.discovery_framework_prefill_questions.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 999fb97add584cfd2ee221a7eeb91a63bc0dc2f76ac452c3b0a0ff2011cfa40f
description: Save your respondents the time and effort of entering responses to specific questions more than one time. Collect new responses for certain questions on assessment forms, and prefill other questions with data retrieved from previous assessment responses. To access data from previously submitted responses, activate the prefill assessment question decision table and the prefill with decision table integration procedure. Then set up Omniscripts to determine whether to prefill questions.
products:
  - Industry Solutions
  - Cross Cloud
release: "264"
---
# Prefill Assessment Questions with Previously Submitted Responses in a Discovery Framework Omniscript

Save your respondents the time and effort of entering responses to specific questions more than one time. Collect new responses for certain questions on assessment forms, and prefill other questions with data retrieved from previous assessment responses. To access data from previously submitted responses, activate the prefill assessment question decision table and the prefill with decision table integration procedure. Then set up Omniscripts to determine whether to prefill questions.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;"><a href="https://help.salesforce.com/s/articleView?id=ind.discovery_framework_editions_permissions.htm&amp;release=264.0.0&amp;type=5" title="Review the supported products and editions for Discovery Framework and Assessments. Then learn about how your product handles permissions and how to assign them.">View supported product editions</a>.</td></tr></tbody></table>

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small permission">
        <colgroup>
          <col style="width:50%">
          <col style="width:50%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="colgroup" class="slds-cell-wrap" colspan="2" style="text-align:center;vertical-align:top;" id="d6524e65">User Permissions
              Needed</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">To enable Prefill Assessments:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">Customize Application</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">To edit omni process assessment question version records and Omniscripts:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">OmniStudio Admin permission set</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">To create, edit, and activate a decision table:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">System Administrator profile</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">To assign permission sets: </td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d6524e65 ">
              <p>Assign Permission Sets</p>
              <p>AND</p>
              <p style="margin-bottom:0;">View Setup and
                Configuration</p>
            </td>

          </tr>
        </tbody>
      </table>

Keep in mind that:

- On Experience Cloud sites, assessments show prefilled questions only for authenticated users, not for guest users.
- To use prefilled questions, community users must have Read access to the Account, Case, Contact, Omni Process, and Response Context fields on the Assessment object. If you don’t want community users to have Read access to these fields, remove the corresponding filters from the GetAssessmentIdForContext Omnistudio Data Mapper.
- Questions are prefilled only on newly opened assessments.
- To prefill a question, the prefill with decision table integration procedure (DiscoveryFramework\_PrefillWithDecisionTable) uses the response from the most recently completed assessment.

To prefill all the questions for which data is available, rather than specific questions, you use a different integration procedure and no decision table. See [Use Data from Previously Submitted Responses in a Discovery Framework Omniscript](https://help.salesforce.com/s/articleView?id=ind.use_data_from_previously_submitted_responses.htm&release=264.0.0&type=5 "Save your respondents the time and effort of entering responses to the same questions on different assessment forms. By adding the prefill integration procedure to an Omniscript, the form can access data from previously submitted assessments. Customize the prefill integration procedure to suit your needs.").

## Explore and Learn

Watch this video to learn how to prefill data from previously submitted assessments.

If you aren’t able to watch the view in full screen, open the video on a new tab: [![Play button](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-ind-discovery_framework-264-0-0-production-enus/e279ff15-cce5-49ed-87b7-c676317e3119/discovery_framework/images/discovery_framework_play_button.png) Learn How to Prefill Data from Previously Submited Assessments](https://salesforce.vidyard.com/watch/8fCvFNdahRLsA1vAmLJsiF).

## Enable Prefill Assessment Questions

Turn on the Prefill Assessment Questions feature so that for specific questions, your users can verify auto-populated data from their previous assessment responses.

Before you enable Prefill Assessment Questions, make sure decision tables are available in your org.

1. From Setup, in the Quick Find box, enter Prefill, and then select **Prefill Assessment Question Settings**.
2. Enable **Prefill Assessment Questions**.
3. Follow the guided setup steps to set up prefill assessment questions and assign permissions for decision tables.

## Set Up Prefill Questions

Omni process assessment question version records represent questions in assessments. In the records that correspond to questions to prefill, select the Prefill checkbox.

1. Open the omni process assessment question version record that corresponds to a question to prefill and a related Omni process ID.
    
    In the Omni Process Assessment Question Version list view, make sure you select the correct version record. If you have multiple versions of an Omni process, the same question can appear in all of them, but there’s a unique omni process assessment question version record ID for each question version.
2. Select **Prefill**.
3. If you activated the Prefill Assessment Question decision table previously, refresh it. You must refresh the decision table after you modify a question version’s Prefill setting.

## Activate the Prefill Assessment Question Decision Table

The Prefill Assessment Question decision table is automatically created when you turn on Enable Prefill Assessment Questions. The table determines whether to prefill assessment questions based on prefill settings in Omni Process Assessment Question Version records.

If you want to evaluate other business rules before a question is prefilled, update the Prefill Assessment Question decision table or create a custom decision table.

1. From Setup, in the Quick Find box, enter Decision Tables, and then select **Decision Tables**.
2. Click **Prefill Assessment Question**.
3. To use the decision table as is, activate it. You can skip the next step.
4. If you want to evaluate other business rules before a question is prefilled, customize the decision table.
    1. Deactivate the decision table.
    2. Add inputs and outputs. If you add outputs, you must also customize the PrefillAssessmentWithDecisionTable Integration Procedure.
    3. Save your changes.
    4. Activate the decision table.
5. Copy the ID of the decision table from the URL of the decision table page. You need the ID when you add the decision table property to Omniscripts later.
    
    The decision table ID is the string of characters that appears in the URL after **DecisionTables/**.
    
    ![Decision table URL with ID highlighted](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-ind-discovery_framework-264-0-0-production-enus/e279ff15-cce5-49ed-87b7-c676317e3119/discovery_framework/images/discovery_framework_assessments_prefill_decision_table.png)

## Add the Decision Table Property to Omniscripts

Specify the ID of the Prefill Assessment Question decision table in Seed Data JSON. The table ensures that the correct assessment questions are prefilled.

1. In an Omniscript, click **Setup**.
2. In the Seed Data JSON section, click **+Add New Key/Value Pair**.
3. For Key, enter PrefillDecisionTableId. For Value, enter the ID of the Prefill Assessment Question decision table you activated.
    
    To find the decision table ID, open the decision table. The decision table ID is the string of characters that appears in the URL after **DecisionTables/**.
    
    ![Decision table URL with ID highlighted](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-ind-discovery_framework-264-0-0-production-enus/e279ff15-cce5-49ed-87b7-c676317e3119/discovery_framework/images/discovery_framework_assessments_prefill_decision_table.png)
4. Repeat these steps for each Omniscript that launches an assessment with questions to prefill.

## Add the Prefill Integration Procedure to Omniscripts

Use the DiscoveryFramework\_PrefillWithDecisionTable Integration Procedure to prefill assessment questions. Activate the Integration Procedure and then add the Integration Procedure action to Omniscripts that launch assessments with questions to prefill.

1. In the Omnistudio Integration Procedures list view, under **DiscoveryFramework/PrefillWithDecisionTable**, open **PrefillAssessmentWithDecisionTable**.
2. Activate the Integration Procedure.
3. Open an Omniscript that launches an assessment with questions to prefill.
4. Drag the Integration Procedure action to the canvas. Place it before the element that shows the assessment questions so that the Omniscript evaluates the prefill setting values before it displays the assessment questions.
    
    ![Omniscript canvas with the Integration Procedure action highlighted](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-ind-discovery_framework-264-0-0-production-enus/e279ff15-cce5-49ed-87b7-c676317e3119/discovery_framework/images/discovery_framework_assessments_prefill_ip_action.png)
5. Click the Integration Procedure action and then enter the properties.
    
    1. For **Name**, enter a descriptive name for the action, for example GetPrefillData.
    2. For **Integration Procedure**, select **DiscoveryFramework\_PrefillWithDecisionTable**.
    
    ![Omniscript canvas with the Integration Procedure action properties specified](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-ind-discovery_framework-264-0-0-production-enus/e279ff15-cce5-49ed-87b7-c676317e3119/discovery_framework/images/discovery_framework_assessments_prefill_ip_properties.png)
6. To test prefilled responses, click **Preview**. Enter a context ID such as an account ID or contact ID and confirm questions are prefilled as expected.

## Assign Permissions for Decision Tables

Finally, update the relevant profiles or permission sets for users who complete assessments so that they can invoke the decision table that prefills assessment questions.

1. From Setup, in the Quick Find box, enter Users, and then select **Users**.
2. Assign the appropriate users a profile or permission set with the Run Decision Table permission enabled. See [User Permissions](https://help.salesforce.com/s/articleView?id=platform.admin_userperms.htm&type=5&language=en_US).

#### See Also

- [Decision Table](https://help.salesforce.com/s/articleView?id=sf.concept_decision_table_create.htm&language=en_US)
- [_Developer Guide_: OmniProcessAsmtQuestionVer](https://developer.salesforce.com/docs/atlas.en-us.248.0.industries_reference.meta/industries_reference/sforce_api_objects_omniprocessasmtquestionver.htm)
- [Omniscripts](https://help.salesforce.com/s/articleView?id=xcloud.os_omniscripts_8355.htm&type=5&language=en_US)