Managing SQL Prompt behavior
Published 11 February 2013
You can set various options for how SQL Prompt behaves in the SQL Prompt Options dialog box. This page describes the options available on the first page of the SQL Prompt Options dialog, the Behavior page; for other more specific options, see the following:
- Customizing inserted code
- Options for formatting your code
- Managing connections and memory
- Changing the location of the settings, cache files and snippets folders
- SQL Prompt Labs
To display the SQL Prompt Options dialog box, on the SQL Prompt menu, select Options.
Turning off SQL Prompt code suggestions
To stop SQL Prompt offering code suggestions:
- In SQL Prompt 5.2 and later, clear the Enable code suggestions check box.
- In SQL Prompt 5.1 and earlier, clear the Use SQL Prompt check box.
The suggestions box will not be displayed until you select the check box again.
Turning off the object definition box
When you select a suggestion, the object definition box is displayed, containing information about the selected object. By default, for tables and views, a summary is displayed, listing the column names and data types:
To view the object creation script instead, click the Script tab.
If you don't want the object definition box to be automatically displayed, clear Display object definitions.
You can view the object definition for a specific object in your query by clicking its tooltip.
Viewing tooltips
Object tooltips display the fully qualified object name for an object when you move the mouse pointer over the object name in your SQL script.
For tables, views, and stored procedures, you can click this tooltip to view the object definition.
Tooltips can also be displayed for parameters, including parameters for built-in functions.
If you don't want tooltips to be displayed, clear Objects or Parameters under Show tooltips for in the Tooltips section.
Changing the insertion keys
Insertion keys are the keys that insert the currently selected suggestion into your code:
Insertion keys are also used to insert snippet code when you type a snippet into your query. The default insertion keys are ENTER and TAB.
Restoring options to their default setting
You can reset the options in SQL Prompt in two ways:
- for a specific page in the Options dialog box
- for all options
To restore the options on a single page
Click Restore Defaults in the top right corner:
This will restore only the options on this page to the SQL Prompt defaults.
Options on all other pages are not affected.
To restore all SQL Prompt options
Click Restore All Defaults in the bottom left corner:
Options on all pages are reset to the SQL Prompt defaults.
Restore All Defaults also resets all formatting options. If you want to save your formatting options, you should save them as a style. This allows you to reapply them, even if you have restored all defaults. See Using styles to format your code.