The query window is the heart of this tool set. You can access the Query Window by right clicking on the connection node and selecting Query Window. Here you can write your SQL statements and choose the style of output, such as grid output or text output. As well, you can write and execute multiple statements; however when executing multiple statements you must set the style of the output to text if you wish to retrieve the appropriate data. For example, I want to select a specific employee from the employees table and pull up that employee's job history.
Listing 3: Example Ad-Hoc Multiple Statement
select first_name, last_name, phone_number, hire_date, salary from employees where employee_id = 102;
select * from job_history where employee_id = 102;
Now all there is to do is to click the Execute button and, in your output window, you should see something similar to the following.
Figure 7: Ad-Hoc Multiple Statement Query Editor and Query Output
Another feature that I find beneficial is when you make a SQL syntax error, the query output tells you exactly what the problem is along with the relevant Oracle error code. This type of feedback makes it a much simpler process to pinpoint where your mistakes reside and what they are.