Datapools are edited using the Datapool Editor. The editor contains the following tabs:
This tab provides an overview of the datapool, including its general information, variables, and equivalence classes.
This tab contains the following sections:
Contains the datapool's name, description, and file path within the workspace. The datapool's name1 and description are editable.
Contains the variables associated with the datapool.
Variables can be added to the list by clicking the Add button.
Selected variables can be removed (Remove), moved up (Up), or moved down (Down).
Variable names can be edited by double-clicking the variable or selecting the variable and pressing F2.
Contains the equivalence classes associated with the datapool.
Equivalence classes can be added to the list by clicking the Add button.
Selected equivalence classes can be removed (Remove), moved up (Up), moved down (Down), or opened in the associated tab (Open...).
Equivalence class names can be edited by double-clicking the equivalence class or selecting the equivalence class and pressing F2.
1 Datapools have a file name and logical name. The logical name is used in the Test Navigator of the Test Perspective, dialogs, editors, and wizards to represent the datapool. The file name represents the datapool file (*.datapool) within the workspace. When the datapool is created, the logical name defaults to the file name (excluding the .artifact file extension) and may be modified without modifying the file name. The logical name allows customization of the datapool name without affecting the file name within the workspace.
This tab contains the datapool table with the variables (or columns) for the datapool, records (or rows) for the equivalence class, and cells for the records:
Each variable has an associated name and type (for example, String, Number, Boolean, Enumeration, and Complex) that are used in the variable name (for example, <variable name>::<variable type>) in the datapool table. Each variable is positioned in the datapool table relative to the other variables in the datapool. Variables may be encrypted for sensitive data, such as user identifiers. Variables are encrypted with a password for the datapool.
Variables can be inserted (select the variable in the datapool table to insert the new variable before and <right-click> > Insert Variable... or Ctrl+Insert), removed (select the variable in the datapool table and <right-click> > Remove Variable or Ctrl+Delete), and their properties (name, type, position, encryption, and password) edited (select the variable in the datapool table and <right-click> > Edit Variable... or select the variable name header in the datapool table).
Each record has an associated number displayed in the first column in the datapool table. Each record is positioned in the datapool table relative to the other records in the equivalence class.
Records can be inserted (select the record in the datapool table to insert the new record before and <right-click> > Insert Record, Insert or select the last record in the datapool table and Enter), removed (select the record in the datapool table and <right-click> > Remove Record or Ctrl+Delete), and their properties (position) edited (select the record number in the first column in the datapool table and <right-click> > Edit Record...).
Multiple records can be selected (select a record or cell in the datapool table and <right-click> > Select All Ctrl+A, Ctrl+A, or Edit > Select All Ctrl+A, hold Ctrl and click multiple records in the datapool table, or select a starting record in the datapool table, hold Shift, and press Up, Down, Home, End, PgUp, PgDn, or click an ending record in the datapool table) and removed (select the record number for any selected row in the first column in the datapool table and <right-click> > Remove Records or Ctrl+Delete).
Individual records can be selected (click the record number in the first column in the datapool table) and cut (select the record number in the first column in the datapool table and <right-click> > Cut, Ctrl+X, or Edit > Cut) and copied (select the record number in the first column in the datapool table and <right-click> > Copy, Ctrl+C, or Edit > Copy). A cut or copied record can be pasted (select the record number in the first column in the datapool table and <right-click> > Paste, Ctrl+V, or Edit > Paste) to any selected row.
Multiple records can be selected (select a record or cell in the datapool table and <right-click> > Select All Ctrl+A, Ctrl+A, or Edit > Select All Ctrl+A, hold Ctrl and click multiple records in the datapool table, or select a starting record in the datapool table, hold Shift, and press Up, Down, Home, End, PgUp, PgDn, or click an ending record in the datapool table) and cut (select the record number for any selected row in the first column in the datapool table and <right-click> > Cut, Ctrl+X, or Edit > Cut) and copied (select the record number for any selected row in the first column in the datapool table and <right-click> > Copy, Ctrl+C, or Edit > Copy). Cut or copied records can be pasted (select the record number for any selected row in the first column in the datapool table and <right-click> > Paste, Ctrl+V, or Edit > Paste) to the same number of selected rows.
Cells can be edited by double-clicking the cell in the datapool table or selecting the cell in the datapool table and pressing F2.
Individual cells can be selected (click the cell in the datapool table) and cut (select the cell in the datapool table and <right-click> > Cut Ctrl+X, Ctrl+X, or Edit > Cut Ctrl+X), copied (select the cell in the datapool table and <right-click> > Copy Ctrl+C, Ctrl+C, or Edit > Copy Ctrl+C), and removed (select the cell in the datapool table press Delete, Backspace, type new content, paste a copied cell, or paste the system clipboard). A cut or copied cell or the system clipboard can be pasted (select the cell in the datapool table and <right-click> > Paste Ctrl+V, Ctrl+V, or Edit > Ctrl+V Paste) to any selected cell.
Cells can be searched and replaced (select a record or cell in the datapool table and <right-click> > Find/Replace... Ctrl+F, Ctrl+F, or Edit > Find/Replace... Ctrl+F). The scope of the search and replace can be limited to selected records (select a record or cell in the datapool table and <right-click> > Select All Ctrl+A, Ctrl+A, or Edit > Select All Ctrl+A, hold Ctrl and click multiple records in the datapool table, or select a starting record in the datapool table, hold Shift, and press Up, Down, Home, End, PgUp, PgDn, or click an ending record in the datapool table and right-click the record number for any selected row in the first column in the datapool table and <right-click> > Find/Replace... Ctrl+F, Ctrl+F, or Edit > Find/Replace... Ctrl+F and select Selected lines in the Scope section). When searching, the next cell containing one or more occurrences of the search string is selected. When replacing, all occurrences of the search string are replaced by the replace string in the selected cell. Note, encrypted cells are not searched or replaced due to the sensitive nature of the data. To search and replace encrypted cells, decrypt the variable, perform the search and replace operations, and re-encrypt the variable.
2 Each equivalence class has an associated tab named <Equivalence Class Name>.
Related tasks
Creating a datapool
Importing a Comma-Separated Value (CSV) file as a Datapool
Exporting a Datapool as a Comma-Separated Value (CSV) file
Related samples
Tutorial: Accessing a datapool from a TPTP JUnit test