Adding Dataset Mapper
You can include a Dataset Mapper in a compound test or a schedule to assign the dataset values to the variables that are defined in multiple tests. In previous releases, to apply the dataset values to multiple tests, you had to associate the dataset to each test. The Dataset Mapper is able to map the dataset columns with the variables.
Before you begin
About this task
For the Dataset Mapper to fetch the test variables, in the Variable Details section of the Test editor, you must set the Visible In field for the variable to All tests for this user. You can also fetch the variables from the custom code calls.
Procedure
- In the Schedule or Compound test editor, click .
-
In the Select Dataset dialog box, select a dataset to use for the
tests and click OK.
To change the dataset after it is associated, in Dataset Mapper Details, click Browse and select another dataset.
-
Select whether the test will make the data in the dataset record permanent for each virtual
user.
By default, one row is retrieved from the dataset for each execution of a test, and the data in the dataset row is available to the test only for the duration of the test. Select Fetch only once per user to specify that every access of the dataset from any test being run by a particular virtual user will always return the same row.
To illustrate how these options affect the rows that are returned, assume that a test contains a loop which accesses a dataset. The loop has two iterations. The following table shows the row that is accessed in each iteration:Dataset option Iteration 1 Iteration 2 Sequential and Private row 1 row 2 Shared and Shuffled row x row y Fetch only once per user row x row x - In the Columns mapping table, the Column is automatically filled with the column names from the dataset.
- To use the variable names from the test, click the cell and click the Ellipsis button and select the variable. By default, the variable names are also created with the same names as the dataset columns.
- To fetch all the dataset values, put the Dataset Mapper in a loop. Select the Dadtapool Mapper in the schedule and click .
- Save the changes.