CTAS
How can I create table as select CTAS in oracle
WEB
The Create table as select CTAS statement can be used to change storage parameters for a table INITIAL NEXT. Without specifying tablespace Create Table as. WEB If you dont want to use dbms_redefinition the Create Table As Select CTAS statement is one.
WEB
How can I create table as select CTAS in oracle Asked 12 years 3 months ago Modified 9 years 8 months ago. WEB Create table as select CTAS has the following parsing. Hi Tom If you want to add several.
WEB
-Use CTAS to create a work table by selecting only the current partition. Initial new_initial next new_next freelists new_freelist_number as..
The Create table as select CTAS statement can be used to create a new table by selecting data from an existing table.
The CTAS statement has the following syntax:
CREATE TABLE new_table_name AS SELECT column_list FROM existing_table_name;
The new table will have the same columns as the existing table, but it will be created in a different tablespace.
The CTAS statement can be used to create a new table with different storage parameters than the existing table.
For example, the following statement creates a new table called new_table
with the same columns as the existing table existing_table
, but with a different tablespace and storage parameters:
CREATE TABLE new_table AS SELECT * FROM existing_table TABLESPACE new_tablespace STORAGE ( INITIAL 10M NEXT 10M PCTINCREASE 10 );
The CTAS statement can also be used to create a new table with a different partition key than the existing table.
For example, the following statement creates a new table called new_table
with the same columns as the existing table existing_table
, but with a different partition key:
CREATE TABLE new_table AS SELECT * FROM existing_table PARTITION BY RANGE (column_name) ( PARTITION p1 VALUES LESS THAN (10), PARTITION p2 VALUES LESS THAN (20), PARTITION p3 VALUES LESS THAN (30) );
The CTAS statement is a powerful tool that can be used to create new tables with different storage parameters and partition keys than the existing tables.
Komentar