Database checkpoints

Relevant for: GUI tests and scripted GUI components

You can use database checkpoints to check databases accessed by your application, and to detect defects. To do this, you define a query on your database. Then you create a database checkpoint that checks the results of the query.

Define a database query in the following ways:

  • Using Microsoft Query. You can install Microsoft Query from the custom installation of Microsoft Office.

  • By manually defining an SQL statement.

You create a database checkpoint based on the results of the query (result set) you defined on a database. You can create a check on a database to check the contents of the entire result set, or a part of it. UFT captures the current data from the database, saves this information as expected data, and inserts a database checkpoint step.

When you create a new database checkpoint, all cells contain a blue check mark, indicating they are selected for verification. You can select to check the entire results set, specific rows, specific columns, or specific cells. UFT checks only cells containing a check mark.

You can also specify the way UFT identifies the selected cells. For example, suppose you want to check the data that is displayed in the first row and second column in the Checkpoint Properties Dialog Box. However, you know that each time you run your test or scripted component, it is possible that the rows may be in a different order, depending on the sorting that was performed in a previous step. Therefore, rather than finding the data based on row and column numbers, you may want UFT to identify the cell based on the column name and the row containing a known value in a key column.

During the run session, the database checkpoint compares the current data in the database to the expected data defined in the Checkpoint Properties Dialog Box If the expected data and the current results do not match, the database checkpoint fails.