You can use criteria to search for and identify archive files that contain specific data. You can also use the same or similar criteria to select and restore a subset of data from an archive file.
Two types of selection criteria can be used in a restore process:
When running the restore process from the graphical user interface, you can use shortcut menu commands to apply local or global selection criteria to any archive file referenced in the restore request. You can also copy global selection criteria and apply it as local, modifying or adding to the copied criteria, as necessary. Any restore request settings to apply criteria to listed files are disabled in an automated process for which archive file overrides are provided, or in an automated search and restore process. See Archive files list.
Search or global selection criteria can be applied to several archive files, even if the data models are not exactly the same.
Use the Index Search Selection Criteria dialog to define search criteria for any table in any archive file listed in the Select Archive File(s) dialog. Use the Global Selection Criteria dialog to define selection criteria for any table in any archive file processed using the restore request.
The tabs on the Index Search Selection Criteria dialog and the Global Selection Criteria dialog are alike and the methods used to define search criteria are the same as those used to define global selection criteria. Although the following discussion concerns the Global Selection Criteria dialog, the information also applies to the Index Search Selection Criteria dialog as well as to the Column Criteria and SQL tabs on the Local Selection Criteria dialog.

Click the down arrow to select from an alphabetical list of all tables in all archive files referenced by the restore request or, when defining search criteria, the Select Archive File(s) dialog.
The dialog has two tabs. Use the Column Criteria tab to define selection criteria for any column in the selected table, or the SQL tab to define an SQL WHERE clause for the table. If you define both column criteria and an SQL WHERE clause for a table, the specifications are logically ANDed.
Use the Column Criteria tab to specify criteria for one or more columns in the selected table.
Option for combining criteria for multiple columns. Select:
For example: CUSTNAME > 'M' AND STATE = 'NJ'
For example: CUSTNAME > 'M' OR STATE = 'NJ'
Name of each column. For convenience, you can rearrange the order in which the columns are displayed by dragging the grid row number. You cannot modify column names.
Because the data model for the production database can change over time, two or more versions of a table might be represented in the listed archive files. For example, the ORDERS table in a recent file might include a column, ORDER_SALESMAN that is not present in earlier files. Thus, a superset of column names from all versions of the selected table is displayed in the dialog.
To enter selection criteria for a column, click the Operator grid cell and select an operator from the list. Enter a value in the Selection Criteria cell. The data types of values for selection criteria must be appropriate for the column and conform to SQL syntax. Any variables must be defined in the current access definition. You cannot use variables on the Global Selection Criteria or Index Search Selection Criteria dialog. In entering criteria, the following separators are valid: colon (:), space ( ), slash (/), minus (-). The variable delimiter in a restore process is a colon (:) and cannot be modified. To validate selection criteria, click outside the grid row. If the criteria is invalid, a message is displayed.
You must use these formats when specifying date/time selection criteria:
For selection criteria that is more complex than can be defined on the Column Criteria tab of the Global Selection Criteria dialog, use the SQL tab to create an SQL WHERE clause.
For example, to select the desired rows from a table, you may need a combination of AND and OR logical operators.

Enter the SQL WHERE clause of the SELECT statement.
A list of the columns in the table. Select a column name to add it to the SQL WHERE clause, positioned ahead of the cursor.
Since the data model of the production database may change over time, two or more versions of a table may be represented in listed Archive Files. For example, the ORDERS table in a recent Archive File may include a column, ORDER_SALESMAN that is not present in earlier files. Thus, a superset of column names from all versions of the selected table is displayed in the dialog.
A list of valid operators and symbols you can use in the SQL WHERE clause. Select an operator to insert it before the cursor position.
You can define local selection criteria for any archive file referenced in the Restore Request Editor. Local selection criteria apply to a specific archive file only and are typically used in a unplanned restore process that is run from the graphical user interface.
To define local selection criteria, right-click an archive file name in the Restore Request Editor and click Apply Local Selection Criteria to open the Local Selection Criteria dialog.

The selected archive file name and a list of tables in the file are displayed at the top of the Local Selection Criteria dialog. In many respects, the Local Selection Criteria dialog is like the Index Search Selection Criteria and Global Selection Criteria dialogs – the Column Criteria and SQL tabs on the three dialogs are exactly the same. For information about defining selection criteria or an SQL WHERE clause, refer to Define search or selection criteria.
One of the main differences between the Local Selection Criteria and Global Selection Criteria dialogs is that you can use the Local Selection Criteria dialog to include variables on the Column Criteria and SQL tabs. You can use the substitution variables specified in the current access definition for the archive file. You can add, modify, or delete substitution variables for the current archive file by browsing the access definition from the Restore Request Editor. On the Local Selection Criteria dialog, the variable delimiter is always a colon (:), and cannot be modified.
The Local Selection Criteria dialog includes a third tab, the Point and Shoot tab, which is not on the Index Search Selection Criteria or Global Selection Criteria dialog.
A point and shoot list consists of primary key values, in ASCII format, that are used as criteria to select start table rows. For a selective restore from the graphical user interface, it may be easiest or most convenient to select rows from the start table rather than to devise selection criteria or an SQL WHERE clause.
Use the Point and Shoot tab to select point and shoot options and browse, edit, or create a point-and-shoot list.

Name of the table designated as the start table in the original or a modified version of the access definition used to create the archive file. To change the start table for the restore process, click from the archive file list to open the Access Definition Editor. If the access definition has been modified, click from the archive file list to open the Access Definition Editor.
Click to display the Point and Shoot Editor. Start table rows that satisfy any selection criteria for the table are displayed. You can use the Point and Shoot Editor to select individual rows from the archive file for restoration.
The start table must have a primary key for point and shoot to function. The primary key values of the selected rows are saved in the point and shoot list and used to identify rows to be restored.
The following considerations apply to restore processing using point and shoot lists:
The Point and Shoot Editor displays data from the start table in a browse window. You can use a toolbar in the browse window to select display options and menu choices that pertain to the display.

Number of selected start table rows to include in the Point and Shoot list.
Number of rows in the list that are not listed on the grid. A number greater than zero may indicate that the default qualifier has changed since the list was created or that the list includes rows that do not match current selection criteria.
The first browse window in the Point and Shoot Editor displays the start table rows. A grid column labeled Select provides a check box for each row. Select the check box to include the row in the list. Clear the check box to retract a selection.
Joining tables is useful for inspecting segments of related data to ensure that the appropriate sets of data are selected for restoration. You can join and display rows from related tables, using the Join button on the toolbar. Rows from each joined table are displayed in a separate browse window in the dialog.
In each browse window, data can be navigated and customized using the Find, Exclude, Include, Hide, and Lock options available from the grid heading shortcut menu.
A browse window has the following components:


In columnar format, the column names are displayed across the top of the grid and the data is displayed beneath the headings. Note that the headings for primary key column(s) are in bold typeface.

In many cases, a table is related to two or more tables, creating different paths for joining and browsing the data. Thus, you can join more than one related table to a table. When several tables are joined to a table, the joined tables are "stacked" in a single edit window, in the order in which they were joined, with the most recently joined table displayed and the other tables in the stack hidden. You can display any table in the stack and join other related tables to any table in the stack. Only start table rows can be selected for a point and shoot list, however.

Only one relationship can be used in a join.
In a stack, the name of the displayed table appears in a drop-down list in the browse window. Click the arrow to display the list of tables in the stack. Select a table name from the list to display that table in the browse window.
When a stacked table is displayed, all subordinate joined tables are also displayed. When a stacked table is hidden, all subordinate joined tables are also hidden.