Databases Reference
In-Depth Information
7.
Inspect the execution plan for the
INSERT
statement in step 3:
EXPLAIN PLAN FOR
INSERT /*+ APPEND */ INTO MY_SALES
SELECT * FROM SALES;
SELECT * FROM TABLE(
DBMS_XPLAN.DISPLAY(null,null,'TYPICAL -BYTES'));
8.
Drop the
MY_SALES
table:
DROP TABLE MY_SALES;
9.
Inspect the execution plan for the
CREATE
TABLE
AS
SELECT
statement in step 5:
EXPLAIN PLAN FOR
CREATE TABLE MY_SALES AS SELECT * FROM SALES;
SELECT * FROM TABLE(
DBMS_XPLAN.DISPLAY(null,null,'TYPICAL -BYTES'));
How it works...
In step 2 we create an empty table with the same structure as the
SALES
table and in step 3
we populate the newly-created
MY_SALES
table with all the rows of the
SALES
table.
We can see the results of this operation in the following screenshot: