TOAD Getting Started Guide
TOAD Getting Started Guide
Version 7.0
Quest Software, Inc. 2001. All Rights Reserved.
This guide contains proprietary information, which is protected by copyright. The software
described in this guide is furnished under a software license or nondisclosure agreement. This
software may be used or copied only in accordance with the terms of the applicable agreement.
No part of this guide may be reproduced or transmitted in any form or by any means, electronic or
mechanical, including photocopying and recording, for any purpose other than the purchasers
personal use without the written permission of Quest Software, Inc.
Warranty
The information contained in this document is subject to change without notice. Quest Software
makes no warranty of any kind with respect to this information. QUEST SOFTWARE
SPECIFICALLY DISCLAIMS THE IMPLIED WARRANTY OF THE MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE. Quest Software shall not be liable for any
direct, indirect, incidental, consequential, or other damage alleged in connection with the
furnishing or use of this information.
Quest and TOAD are trademarks of Quest Software, Inc. Other trademarks and registered
trademarks used in this guide are the property of their respective owners.
Contents
C O N T E N T S
TOAD Getting Started Guide
2 INTRODUCTION 7
This guide introduces TOAD. It helps you install and run TOAD. It also introduces
you to some of the TOAD functions and optional modules.
The guide covers the following major topics:
System requirements
Install/uninstall
Registration
Troubleshooting
TOAD files
Optional add-on modules
6
This is an introductory guide. Refer to TOAD Help for the latest information. You
can easily access TOAD Help while in TOAD by pressing the F1 key.
RELEASENOTES.TXT contains the latest information about upgrades and changes.
Note that this guide was prepared in March 2001. New or changed TOAD features
since March 2001 are not reflected in this version of the TOAD Getting Started
Guide.
For details on TOAD, including navigation and main windows, refer to the TOAD
User's Guide.
Remember, you can always access TOAD Help while in TOAD by pressing
the F1 Key.
Introduction
TOAD
TOAD is a powerful low-overhead tool built around an advanced SQL and PL/SQL
editor. It was designed from the developers perspective, and the result is an easy to
use, fast, and effective interface. The GUI object browsers provide quick access to
database objects.
You dont have to be a PL/SQL expert to access database objects when youre using
TOAD. You can view the Oracle Dictionary, tables, indexes, stored procedures, and
more-- all through a multi-tabbed browser.
PL/SQL script writers can use the advanced editing features to save time and
increase productivity. Code can be created from shortcuts and code templates. Even
create your own code templates.
Use TOAD to
Create, browse, or alter objects (tables, views, indexes, etc.) including Oracle8
TYPE objects
Graphically build, execute, and tune queries
Edit and Debug PL/SQL and profile stored procedures including functions,
packages, and triggers
Search for objects
Find and fix database problems with constraints, triggers, extents, indexes, and
grants
8
Install/Uninstall and TOAD Files
This chapter covers the install process for TOAD including an overview of the
TOAD files that are installed. It explains the different types of installs. It also shows
the uninstall procedure.
You can install TOAD from a CD-ROM or installation files you download from the
Quest Software Web site, www.quest.com .
Before installing TOAD, make sure that your system meets the minimum hardware
and software requirements. Also, check your SQL*Net or Net8 setup with another
application, such as Oracle's tnsping utility, to verify your connection with the
database.
System Requirements
TOAD requires either Windows 95, 98, NT 3.51, NT 4.0, or Windows 2000.
If you have SQL*Net (32 bit) installed (or Net8 for Oracle 8 users) and can
connect to Oracle 7 using any of Oracles tools (with the exception of
SQL*Plus), TOAD should operate properly.
10
The current release of TOAD requires SQL*Net (32 bit) or Net8 for Oracle 8 users.
Optional Requirements
Install
To Install TOAD
2 The first install dialog box is a Welcome screen. This ensures that you want to
install TOAD. If you want to cancel, click Cancel. As you progress through the
following dialog boxes, you will have a Back button to go back to the previous
dialog box and a Cancel button to cancel the installation. To progress through the
installation, choose your option for each dialog box and click Next.
3 The next dialog asks you to select the type of installation you want. The choices
are:
TOAD and Personal Configuration Files to PC
Personal Config Files to PC, read TOAD from Network Server
TOAD to Network Server
12
You can only choose one. TOAD always installs its files in a TOAD folder. No
files will be placed in Windows folders or other miscellaneous folders.
4 The next dialog asks you to select your destination directory. The default
directory is C:\Program Files\Quest Software\TOAD, but you can browse through
your directories and select another one if you want TOAD installed in another
directory or another hard drive letter (D, E, F, etc.).
If in the previous step you chose to install some or all of TOAD on a server you
will also be asked for the destination directory for the server install.
5 The next dialog box asks if you want to backup replaced files. If you choose Yes,
then all copies of modified configuration files will be put in a backup folder.
Then, when TOAD updates are performed, your configuration files wont be
overwritten. This only backs up TOAD install files. The default is Yes.
6 If you chose Yes in the previous dialog, the install will ask you to select a backup
directory. The default is the TOAD\BACKUP folder. You can browse through
your directories if you want to choose another location.
It checks your system to see if either SQL*Net or Net8 are installed properly,
such as ORACLE_HOME, PATH environment variable, and prerequisite
SQL*Net/Net8 files.
It asks you if you would like a TOAD desktop shortcut icon. If you choose Yes it
creates a TOAD shortcut and an icon on your desktop.
After TOAD makes these checks, a progress bar displays which shows the install
program uncompressing the files and copying the files to their destinations. At the
same time, 2 log files are created in the TOAD folder: INSTALL.LOG and
INSTALL.TXT.
INSTALL.TXT is also created by the installation, but it has a different format. Its
user-friendly approach is easier to follow. Its basically an outline of how the
installation script went. If there is an installation problem, such as a problem
creating icons, the file can be helpful in determining why that problem is
occurring. Here is a section from an INSTALL.TXT file. Notice how different its
format is from the INSTALL.LOG.
9 TOAD will also display dialogs relevant to any add-on modules that you have.
Chapter 3 Install/Uninstall and TOAD Files 15
10 The finish dialog will display indicating installation has been completed.
TOAD will ask you if you want to read the README.TXT. The default choice is
Yes. If you choose Yes, TOAD will put the README.TXT into notepad for you to
read.
You should refer to the RELEASENOTES.TXT for the latest information about
TOAD upgrades, changes, fixes, and issues.
16
TOAD files
When TOAD is installed, files are copied into the appropriate directories. As you
work with TOAD more files are created by you. This section is an overview of some
of the TOAD files that are in your TOAD folder.
TOAD.EXE
This is the TOAD application file.
TOAD.HLP
This is the TOAD help file.
ROBOEX32.DLL
The DLL file for the TOAD Help files
TOAD.CNT
The contents for the TOAD Help files
UNINSTAL.EXE
This is the uninstall engine. You select uninstall from the start menu, or control panel
add/remove programs applet.
The uninstall engine reads and undoes everything that it finds in the INSTALL.LOG.
HINTS.TXT
ASCII file for hints for the toolbar buttons and status panel descriptions.
SqlEdit=Open a new SQL Window|Open a new SQL Window A section from the HINTS.TXT file
Browser=Open a new Schema Browser Window
ProcEdit=Open a new Procedure Edit Window
SqlBuilder=Open a new SQL Builder
SqlModeler=Open a new SQL Modeler
ExPlanResults=Explain Plan Window|Show previous Explain Plan Results
DBMS=Open a new DBMS Output Window
Execute=Execute statement|Execute the complete or highlighted statement ( F9 )
ExecutePartial=Run current statement|Run the statement at the cursor ( Shft-F9 )
ExecuteScript=Execute all of current window as script
RecallSql=Recall Previous SQL ( F8 )
RecallPers=Recall Personal SQL
NAMEDSQL .DAT
A list of user named SQLs
PERSSQLS.DAT
A list of user personal SQLs
SQLS.DAT
A list of last x SQLs executed by the user
README.TXT
A legal reminder, install notes, license files, and other TOAD information
RELEASENOTES.TXT
Includes important information about upgrades, changes, fixes, and issues
REVBASE.DLL
Interface from TOAD to Oracle Knowledge Base
TOAD.INI
Initialization parameters file
18
TOADLOAD.WAV
Croak sound, plays when TOAD.EXE is invoked
SCHEMA.FLT
Schema filters files. If you use browser filters, TOAD creates SCHEMA.FLT files.
TOADREPORTS.EXE
The executable that launches the Reports feature from within TOAD. It can only be
launched from within TOAD.
REPORTSPARAMS.INI
Initialization files for the Reports feature
FMTPLUS.DLL
Contains the code that TOAD uses from Formatter PlusFormat Code, Profile
Code, and Show Inline Advice
FMTOPTIONS.EXE
Launched when you select View > Formatting Options. This window lets you
configure how Formatter Plus will operate. The settings for the configuration
window are saved in FMTOPTIONS.INI
FMTPLUS.OPT
The settings for Formatter Plus that the View > Formatting Options window
configures are saved in FMTPLUS.OPT.
Chapter 3 Install/Uninstall and TOAD Files 19
The TEMPS folder contains 12 text files associated with SQL functions Help. To see
the SQL Help Templates, go to the toolbar in the SQL Edit Window and select Show
SQL Help.
4 templates are for the Procedure Editor in the Procedure Editor Window.
NEWFUNC.SQL
NEWPACK.SQL
NEWPROC.SQL
NEWTRIG.SQL
3 files are associated with syntax highlighting in the SQL Editor and Procedure
Editor.
PLSQLSCR.TXT
Main file
SHORTSCR.TXT
The default PLSQLSCR.TXT=SHORTSCR.TXT
LONGSCR.TXT
Can copy LONGSCR.TXT over PLSQLSCR.TXT for more functionality
Syntax highlighting support also includes HTML, INI, JAVA, and TEXT files.
HTMLSCR.TXT
INISCR.TXT
JAVASCR.TXT
TEXTSCR.TXT
NOTOAD.SQL
Creates temp tables without an external TOAD user schema, replaces the
TOADPREP.SQL
This creates temp tables in your current schema.
Chapter 3 Install/Uninstall and TOAD Files 21
EXPLAN.SQL
User customizable SQL for showing previous Explain Plan SQL results. You can
preview your SQL results before you execute them.
ALIASES.TXT
List of user-defined table aliases
For example, Employee table can be set up as alias EMP.
PLSQL.DCI
Code completion templates activated in the SQL Edit or Procedure Edit window by
typing a couple of letters and <CTRL> + <SPACE> or to access the whole list press
<CTRL> + <SPACE>
The user can customize the file by manually editing PLSQL.DCI with notepad
or
From the edit menu Editor Options dialog tab for editing code templates.
Code completion templates support also includes HTML, INI, JAVA, and TEXT
files.
HTML.DCI
INI.DCI
JAVA.DCI
TEXT.DCI
TOADPROFILER.SQL
Script available in Oracle 8i. Sets up profiler analysis.
As TOAD runs a procedure, the profiler keeps statistics. It can see where the
bottlenecks are so that you can improve them.
TOADSECURITY.SQL
A script that sets up TOAD security features.
It enables or disables certain buttons or functions.
For example, it can prevent certain TOAD users from dropping tables.
It does not affect Oracle security, such as object grants or system privileges.
22
PLSQLSUB.TXT
List of AutoCorrect substitutions.
If you mistype and press <SPACE>, the word you incorrectly typed is autoreplaced
if its in PLSQLSUB.TXT.
Example; teh would be replaced with the
You can add words by accessing the editor options dialog
or Notepad - PLSQLSUB.TXT.
Other SUB.TXT files are supported for HTML, INI, JAVA, and TEXT files.
HTMLSUB.TXT
INISUB.TXT
JAVASUB.TXT
TEXTSUB.TXT
SCHEMA_DATABASE.LST
Lists of Oracle users for the selected schema/database.
You can use the View > Oracle Users List dialog to select which users schemas
you want to see. This saves query time.
TOADSTATS.INI
Warning levels for server statistics window. You can set thresholds for when a
warning or error will display.
warning pink
error red
If you select server installation, the files TOAD installs on the server include:
TOAD.EXE
TOAD.HLP
REVBASE.DLL
and
SQL Help Templates
New Procedure Templates
Code Completion Templates
in \TEMPS folder
Chapter 3 Install/Uninstall and TOAD Files 23
Uninstall
If you uninstall TOAD, it might not totally uninstall. When you use TOAD, you
create new TOAD files such as SQL scripts, data output, or temp files. When you
run uninstall, TOAD has no way of knowing what those files are. So it wont remove
new TOAD files that youve created. Youll have to manually delete them.
Two methods allow you to uninstall TOAD.
So, when network installation is involved, remember that any TOAD components
that are installed on the server cannot be uninstalled. They will have to be manually
deleted. When TOAD files are installed on the server they always include
TOAD.EXE and TOAD.HLP. TOAD files on the client (workstation) can be
uninstalled.
Registration
This chapter discusses how to register trial and commercial versions of TOAD. This
chapter also covers the purchase procedure for TOAD.
Before you register the trial version of TOAD you need your registration
key. The PL/SQL Debugger and DBA modules are activated in the
trial key.
If you have previously used a TOAD trial key you will get an Invalid Key
message. A trial key can only be used once, even between different versions of
TOAD.
26
Registration Key
If your registration key has not been activated after a certain time period, it expires.
This is to ensure that you are not evaluating an old copy of TOAD. We want users to
have the latest and greatest copy to evaluate. So, if your unactivated key expires,
download the latest trial copy and get your new registration key, or call Quest Sales
at 949-754-8000 for a trial extension.
If you are satisfied with the trial version and want to purchase the commercial
license key, refer to the next section. Remember, youll need to update your license
key through Help > Register TOAD.
Chapter 4 Registration 27
Purchase
To purchase the latest version or place a large order you can either contact Quest
Sales at 949-754-8000 to discuss payment options
or
Visit the Quest Software Web site at www.quest.com .
Youll receive a temporary key in the download.
After your order is processed, your permanent license key is sent to you. Then go to
the Help menu, click Register TOAD, and enter your new authorization key
number, also known as the license or registration key number. Enter the Site
Message such as Company Name. In the future, when you download upgrades from
the Quest Web page youll need the license key number. Select Help > Register
TOAD, highlight your number from the authorization key number box, Copy, and
Paste the number.
NOTE: You may need to restart TOAD to reinitialize your options and enable all
functions.
28
The following table shows steps that you can take when encountering an
authorization problem or error in TOAD.
Authorization string has This occurs when the trial authorization for
expired. TOAD has expired.
This chapter introduces you to a few of TOADs many features. To learn more about
these or any other feature refer to TOAD Help and the TOAD Users Guide.
SQL Editor
The SQL Editor lets you type, execute, and tune SQL statements. The SQL window
contains a SQL Editor and a results grid for viewing fetched data.
The window supports standard windows editing commands but includes other
functions such as a gutter for quick multi-line text selection, programmer style
double-click highlighting, and syntax highlighting of categories, keywords, table
names, and more.
The data grid displays the results of SELECT statements. It is user configurable with
resizable and moveable columns, ability to export data to the clipboard or disk,
support for LONG and LONG RAW columns, and more. If the dataset is editable,
additional buttons on the toolbar are enabled (insert, delete, post updates, and more).
The SQL Edit window displays the query in the upper portion of the screen and the corresponding
select statements results in the lower results grid.
Chapter 5 Features 31
Schema Browser
The Schema Browser separates database objects by type, using tabs. So, you can
quickly view all objects of one type with a single click of the mouse. Youll find it a
nice change from other database navigation tools which are often slow, cumbersome,
and burdened with excessive graphics. It also lets you compare details between
objects of the same type with one click. Keyboard users can easily use the scroll keys
to perform the same tasks.
Here, a click on the DEPT table on the Tables tab in the left panel displays the details about the DEPT
table on the Data tab in the right panel.
32
Procedure Editor
The Procedure Editor lets you edit, compile, test, and debug stored procedures and
triggers.
By clicking on the right mouse button or pressing F10 you access a context menu
with numerous options such as Set Bookmark, Uncomment Block, Format
Statement, and Show Edit Toolbar.
A unique feature of the Procedure Editor is its source check in and source check out
buttons. The source you are typing can be directly checked in and out of SourceSafe
or another source control provider.
Options Menu
To access the Options Menu select View > Options. Click a topic from the left panel
and options for that topic appear in the right panel. Click in the boxes or on the item
text to check or uncheck the options. Keyboard users can press the Tab key to move
from the left panel to the right panel and press <SPACE> to check or uncheck boxes.
The Options are:
General
Oracle
SQL Editor
Data Grids
Procedure Editor
Editors
StartUp
Schema Browser
Files
Debugging
Object Browser
Source Control
Printing
DBA
Data Types
Parser Scripts
New Proc Templates
Monitor
Executables
SQL Modeler
34
TOAD Help
To access TOAD Help while in TOAD, simply press the F1 key. TOAD Help
includes contents, a searchable index, and details on TOADs features.
Troubleshooting
Open up the TNSNAMES.ORA file. It should be in the Admin folder. Make sure
the database alias name you are using is in the TNSNAMES.ORA file.
If you are having trouble connecting to Personal Oracle or creating a SQL*Net alias
for PO7 or PO8, then for the database name on the TOAD login window try one of
the following entries:
2:
BEQ-LOCAL
LOCAL
TCP-LOOPBACK
DEMO/DEMO
SCOTT/TIGER
SYS/CHANGE_ON_INSTALL
SYSTEM/MANAGER
Chapter 6 Troubleshooting 37
QUESTION ANSWER
How do I edit the results of a query? In the SQL Edit window, the data grid that displays the results of
the SQL queries is fully editable providing that the query itself
returns an updateable resultset. Query statements MUST return the
ROWID to be updateable.
For example:
select * from employee
would not be updateable whereas:
select employee.*, rowid from employee
would be updateable.
To reduce this obvious nuisance, you can substitute EDIT
EMPLOYEE which TOAD will translate into the updateable
version of the statement.
For example:
edit employee
If the resultset should be editable but remains read-only, make sure
the View > Options > Data Grids > Default to Read-Only
Queries option is not checked (not enabled).
Why can't I see all users in the users Go to the View > Options > Schema Browser > Only Show Users
dropdown lists? That Own Objects in DropDown Lists option. If checked, it will
only show users that own objects. Also go to the View > Oracle
User List which selects a subset of all users.
How can I run multiple copies of Check the View > Options > General > Allow Multiple Copies of
TOAD at the same time? TOAD to be loaded checkbox.
How do I get the PL/SQL Debugger to Purchase the TOAD PL/SQL Debugger option from
work? www.quest.com. Plug in your new License Key into the Help >
Register TOAD dialog. Close and reopen TOAD to reinitialize the
License Key option settings.
Can you see the SQL that TOAD Yes. See Tools > Spool SQL > to Screen or to File.
executes?
38
QUESTION ANSWER
How can I set TOAD to commit See menu item View > Options. On the Oracle node, check the
automatically after every SQL Commit Automatically After Every Statement checkbox. This is
statement I execute? a session level setting which means it affects not only the current
SQL Edit window but all other windows sharing the same session.
When checked, this option forces an automatic COMMIT to be sent
following every statement. When not checked, the user must
manually perform commits when desired. If you attempt to close
TOAD without auto commits, TOAD will ask you if you want to
perform a commit.
How can I cancel long running See menu item View > Options. On the SQL Editor node, check
queries? the Process Statements in Threads/Allow Queries to be
Cancelled checkbox. If checked, TOAD will issue each query in a
separate thread. This will show the <Cancel> button on the SQL
Edit window toolbar to the right of the Change Active Session
button, and will permit the user to cancel a long running query.
How can I improve the Oracle If you
Dictionary query performance? have the DBA Role or
have been granted select privileges to DBA_xxx Views or
have the Select any table system privilege
you can check the Check for Access to DBA Views checkbox in
View > Options, StartUp node. TOAD will then query the Oracle
Dictionary using the DBA_ views, e.g., select * from
dba_tab_columns which is a lot faster than select * from
all_tab_columns because the DBA_ views do not contain any
security features.
How can I limit TOAD's object You can either make TOAD read-only by copying
altering capabilities? READONLY.LIC over TOAD.LIC, or revoking system privs, e.g.,
"create table" from those user accounts, or install TOAD Features
Security by running script TOAD\temps\TOADSecurity.sql, then
administer the lists of who can execute which function in the
Database > TOAD Security dialog.
How do you improve the performance See the View > Options dialog, Data Grids node. Check the Clone
of saving the SQL results grid to a SQL cursor when exporting grid contents checkbox. TOAD will
file? then use a read ahead only cursor, which uses less resources, and
does not have to interact with the grid as it traverses the records.
Chapter 6 Troubleshooting 39
You can get help from the Quest Software Web site at
http://www.quest.com/support/index.html
Products Available
This chapter lists optional products that work with and enhance TOAD.
Quest Software offers the following products. For more information on any of these
products go to www.quest.com or contact Quest sales at 1-800-306-9329. You can
also send email to [email protected].
TOAD PL/SQL Debugger (see the PL/SQL Debugger chapter of the TOAD
Users Guide)
TOAD DBA (see the DBA chapter of the TOAD Users Guide)
SQLab Xpert
SQL Impact
PL/Formatter
Formatter Plus
Knowledge Base for Active PL/SQL Development
Knowledge Base for Oracle Administration
About Quest Software
Contacting Quest
Product information
Phone (USA and Canada): 949-754-8000
Fax (USA and Canada): 949-754-8999
E-mail Sales & Marketing: [email protected]
Web: http://www.quest.com
Mail: 8001 Irvine Center Drive, Irvine, CA 92618
International offices
UK: +44 (1628) 601000
Germany: +49 (211) 770967 0
Australia: +61 (3) 9811-8000
Canada: +01 (905) 804-9480
44
Technical Support
If you have questions about using TOAD, and you cant find the answers in the
TOAD Users Guide or the Help files please contact the technical support staff. The
Help > Support > Email menu item opens your email application with a
pre-addressed email. It automatically includes information about the version of
TOAD you are running. This information helps the technical support staff. You can
then type in information about your question or problem in the body of the letter. If
your question is about an error message, include the error text as well.
The Help > About window displays technical support contact information including
telephone numbers and your version number. When you contact technical support
they will need to know what version of TOAD you are using.
Email: [email protected]
You can create your own support calls online at www.quest.com/support
If you create support calls online, you will also be able to check the status and update
your own calls online.
INDEX
A M
ALIASES.TXT 21 Menu 33
Authorization Errors 28
N
D
NAMEDSQL .DAT 17
disk space 10 NOTOAD.SQL 20
E O
Error Messages 28 Options Menu 33
EXPLAIN.SQL 21
P
F
PERSSQLS.DAT 17
FMTOPTIONS.EXE 18 PL/Formatter 41
FMTPLUS.DLL 18 PLSQL.DCI 21
FMTPLUS.OPT 18 PLSQLSCR.TXT 20
Formatter Plus 41 PLSQLSUB.TXT 22
FULLTOAD.LIC 16 Procedure Editor 32
H Q
Help 6 Quest Software
HINTS.TXT 17 Contacting 43
Technical Support 44
I
R
Install 9, 11
Install.Log 13 README.TXT 15, 17
READONLY.LIC 16
K
Registration 25
Knowledge Base for Active PL/SQL RELEASENOTES.TXT 6, 15, 17
Development 41 REPORTSPARAMS.INI 18
Knowledge Base for Oracle Administration 41 Requirements 9, 10
REVBASE.DLL 17
L ROBOEX32.DLL 16
LONGSCR.TXT 20
46
S TOAD Help 6
TOAD PL/SQL Debugger 41
Schema Browser 31
TOAD User's Guide 6
SCHEMA.FLT 18
TOAD.CNT 16
SHORTSCR.TXT 20
TOAD.EXE 16
Spool SQL 37
TOAD.HLP 16
SQL Editor 29
TOAD.LIC 16
SQL Impact 41
TOADLOAD.WAV 18
SQLab Xpert 41
TOADPREP.SQL 20
SQLS.DAT 17
TOADPROFILER.SQL 21
StartUp 33
TOADREPORTS.EXE 18
T TOADSECURITY.SQL 21
TOADSTATS.INI 22
TNS Admin Value 36
TOAD U
Schema 36
UNINSTAL.EXE 16
TOAD DBA 41
Uninstall 23
TOAD Getting Started Guide 6