Query execution history

The Execution History window allows you to view, search, edit the executed queries. To open the window, point to Other Windows in the View menu, and then click Execution History.

The window looks in the following way:

History Execution Window

Setting Up Execution History behavior

To set up behavior of execution history:

  1. On the Tools menu, click Options. The Options dialog box opens.
  2. Navigate to Environment, Documents, Execution History.
  3. To enable storing query execution history, select the check box next to the Store executed queries within option, and set the number of days to store executed queries.
  4. Optionally, modify the path to store the execution history database, maximum script size to store, and timeframe for default output of execution history.

Execution Options

Filtering Execution History

To quickly find the required query, you can:

  • Type the search string into the Search box and specify query execution time frame.
  • Use sorting, grouping, and filtering.

Filtering History

Editing Query

To edit an executed query, select it the list, and click Edit Query in the Query DDL section of the window. The query will be opened in a new SQL document.

Editing Query

Download dbForge Studio for SQL Server and try it absolutely free for 30 days!