The editor combines a powerful SQL and procedure editor and debugger into a single interface.
Notes:
To edit SQL
Select Tools | Edit.
Review the following to help enter SQL:
Click to format the code.
Select the block of code in the Editor, and click to validate the syntax.
Note: Toad undoes any changes to the object and data in the database after executing the script (notice that the Result Sets tab is empty). To modify the object and data, you need to execute the script.
Debug code. See About Debugging SQL for more information.
Click to execute SQL on the current server or multiple servers at one time.
To tune SQL, right-click a statement in the Editor and select Advanced | Optimize the Current Statement (available if you purchased a version of Toad that includes the SQL Optimizer). If you have not purchased this version, you can tune the statement by right-clicking it and selecting Advanced | Analyze in Database Engine Tuning Advisor.
You can create TOADSQLFILE.sql in order to use it's contents as template when opening new Editor window. Save it in a root folder for code snippets. See Code Completion Options for more information.
You can specify options for the look and behavior of the SQL Editor by using the Toad Options dialog.
To configure Editor options
To specify one of the following options, select the corresponding page in the Options dialog.
Option Description |
Page in Options Dialog |
---|---|
Display the tabs for the current connection only when using Tabbed windows |
Select Environment | Interface |
Change background color of the Editor | Select Editor | General |
Use connection color as background color | Select Editor | General |
Position Editor tab headers vertically | Select Environment | Interface |
Set options to display line numbers, line modifications, and general text formatting |
Select Editor | General |
Specify options to automatically replace typed text with the correct substitution text |
Select Editor | Auto-replace |
Customize code formatting options including headers and layout characteristics |
Select Editor | Formatter |
© ALL RIGHTS RESERVED. 使用条款 隐私 Cookie Preference Center