Learn more about Toad for SQL Server
at Dell Software

Find solutions and downloads at the
Toad for SQL Server Support Portal

Toad for SQL Server 6.6

You are here: Edit SQL > Debug SQL > Work with Watches > Add Watches

Add Watches

Watches are expressions that can be evaluated and displayed during a debugging session. The current values of the watch expressions are refreshed each time the debugger suspends execution. Watch expressions can be simple (i.e., a local variable or parameter) or complex such as an algebraic expression or a select statement.  

If an expression returns a result set, the records returned display as child nodes in the Watches window.

Caution: The SELECT statement re-executes every time execution suspends (using steps or a halt). This may severely impact performance of the debugger if the query does not execute quickly or returns a large amount of data.

To add a watch from the Editor window

» Place the cursor in front of the variable or expression you want to watch and click on the Debugger toolbar.

To add a watch from the Watches window

  1. Select Debug | Windows | Watches from the menu.

  2. Right-click anywhere in the window and select Add Watch.

  3. Review the following for additional information:

    Scope

    Select one of the following watch scopes:

    • Automatic—Select this to let Toad automatically determine the scope.

    • Parameter—Select this for procedure parameters.

    • Local—Select this for a local variable.

    • Global—Select this for a global variable.

    Expression

    Enter or select an expression to use for the watch.

    Note: This option is only available if you selected Automatic as the scope.

Tips:

  

Related Topics

About Debugging SQL

View Local Watches

View Global Watches 

of