HomeOracle Page 4 - Learning to Query in Oracle XE
Example 3: Dual Tables - Oracle
Querying the database is one of the most common tasks that you may have to carry out routinely. This tutorial shows you the options for running SQL queries and how to run the queries against the database in the Oracle Express Edition, Oracle XE for short.
Another of Oracle's very useful constructs is the Dual table. This is a table with just one column into which you can stuff your own value. Here is what you will get when you describe the Dual table.
If you were to use a select query, Select 'hello' from dual, it would return 'Hello' in the Dummy column.
An example of using Dual
You could run a math function to be evaluated into dummy as shown in the next picture.
Summary
The SQL Command window of Oracle XE has is an extremely intuitive and user-friendly interface to run SQL, PL/SQL queries. The results of running a query against the database are provided in a single, tabbed window. The SavedSQL and history features provide links that will help refining and back tracking previously run queries.