Associating a test value with a datapool column

After you have created a datapool and have enabled your test to use the datapool, you associate a specific value in the test with a specific datapool column.


  1. In the Test Navigator, browse to the test and double-click it. The test opens.
  2. Locate and click a request that contains a value to replace with variable data.

    Clicking a test page shows you a table that lists datapool candidates and correlated data on that page. (If correlated data is not displayed, right-click the table and verify that Show References is selected.) References are shown in blue letters and datapool candidates are shown in black letters.

    table with one black row, showing one datapool candidate

    If the contents of the Value column corresponds exactly with column data in your datapool, click the row, and then click Substitute. The Select Data Source window opens. Skip to step 6. You can ignore step 8, because URL encoding is preselected.

    Otherwise, double-click the row to navigate to the page request that contains the value to replace from a datapool, and continue to the next step.

    The value to replace from a datapool might not be listed in any page table. In this case, manually locate the request string that includes the value.

  3. If the value to replace from a datapool is part of a string that has been designated a datapool candidate, you must remove the light green highlight: right-click and select Remove Substitution. For example, if you searched for doe, john in your test, the datapool candidate in your test is displayed as doe%2C+john. Suppose that you do not want to associate this candidate with a single datapool column that contains data in the format doe, john. Instead, you want to associate doe and john with separate datapool columns. In this case, you must first remove the substitution.
  4. Highlight the value: With the left button pressed, drag your mouse over the value.
  5. Right-click the highlighted value, and select Substitute > Select Data Source.
    The Select Data Source window opens.
    Note: To use a datapool that is not listed, click Datapool: the Select datapool column window opens.
  6. Click the name of the datapool variable, or column, to associate with the test value.
  7. Click Select.

    To indicate that the association has been set, the highlighting for the selected test value turns dark green, and the datapool table for this page is updated as shown in the example.

    table with two green rows

  8. Optional: Encode variable data when it is substituted from a datapool.

    If a test value contains special characters such as spaces or commas, click the row and select URL Encode. With this option, special characters are encoded when variable data is substituted from a datapool. For example, data that is space-separated in a datapool column might need to be encoded. When URL encoding is enabled, John Doe is substituted as John%20Doe. If URL encoding is not selected, the variable data that is substituted is literal. Do not enable URL encoding for datapools that contain data that is already encoded.

  9. Optional: If you substitute an element of a page with a datapool column, to view the substitutions in the Page Elements report, in the Test Elements Details area of the request click the Use the substituted URL in performance reprots check box.
  10. Save the test.