set autotrace traceonly explain, and condition : autotrace « SQL PLUS Session Environment « Oracle PL/SQL Tutorial






SQL>
SQL>
SQL> create table t
  2  as
  3  select mod(ROWNUM,3) a, ROWNUM b, ROWNUM c
  4    from all_tables;

Table created.

SQL>
SQL> set autotrace traceonly explain
SQL> select * from t where b = 1 and c = 1;

Execution Plan
----------------------------------------------------------
Plan hash value: 1601196873

----------------------------------
| Id  | Operation         | Name |
----------------------------------
|   0 | SELECT STATEMENT  |      |
|*  1 |  TABLE ACCESS FULL| T    |
----------------------------------

Predicate Information (identified by operation id):
---------------------------------------------------

   1 - filter("C"=1 AND "B"=1)

Note
-----
   - rule based optimizer used (consider using cbo)

SQL>
SQL>
SQL> set autotrace off
SQL>
SQL> drop table t;

Table dropped.








29.36.autotrace
29.36.1.Autotrace explain a select statement
29.36.2.autotrace traceonly statistics
29.36.3.set autotrace traceonly statistics to trace a function
29.36.4.set arraysize 5
29.36.5.Introduction to SQL Tuning - Workshop
29.36.6.set autotrace traceonly explain for bitmap index
29.36.7.set autotrace traceonly explain, and condition
29.36.8.set autotrace traceonly statistics
29.36.9.set autotrace traceonly statistics for 'select * from tableName'
29.36.10.AUTOTRACE exists (subquery)
29.36.11.AUTOTRACE table joining
29.36.12.AUTOTRACE table joining and aggregate function