Altova DatabaseSpy 2024 Professional Edition

Naming Result Tabs

Home Prev Top Next

When you execute a script that contains more than one SELECT query, the results of each query are displayed in separate result windows. By default, these windows are called "Result1", "Result2", etc. Using targets, you can specify more meaningful names for query result windows.

 

Prerequisites

The Show multiple results stacked ic_result-tabs option must be switched off.

Select either "Semicolons" or "SQL Grammar" in the Group statements for execution with drop-down list in the Properties window. Otherwise, the query is still executed, but the results are displayed in unnamed result tabs.

To name a target result window:

1.Place the cursor anywhere in the SELECT statement. Click the Current statement ic_select-entire-stmt button (Shift+Alt+Enter) in the SQL Editor window. This selects the entire statement.

2.Click the Define Target Name ic_insert-target-single button in the SQL Script toolbar. The text -- target: Result appears above the statement.

target_result

3.Change the text "Result" as desired.

target_result_new_name

4.In the Properties window, make sure that either "Semicolons" or "SQL Grammar" is selected in the Group statements for execution with drop-down list.

5.Click the Execute ic_execute-sql button or press F5.

The results appear in a Result window that has a tab with the text that you specified as target, e.g., zookeepers.

sql_target-zookeepers

© 2017-2023 Altova GmbH