Hi,
I want to create a table from select with some additional columns with NULL value.
create table test01
(
col1 number,
col2 varchar2(10)
);
insert into test01 values(1,'a');
insert into test01 values(2,'e');
insert into test01 values(3,'d');
insert into test01 values(4,'c');
insert into test01 values(5,'b');
commit;
I want to create a table with additional column with null value. Is it possible without an update?
SQL> create table test02
2 (
3 col3 number,
4 col4 varchar2(20),
5 col5 date
6 )
7 as
8 select col1 as col3, col2 as col4, null as col5 from test01;
col3 number,
*
ERROR at line 3:
ORA-01773: may not specify column datatypes in this CREATE TABLE
SQL>