create table test
(owner varchar2(30),
object_name varchar2(128),
object_id number,
object_id_2 number,
create_date date default sysdate);
create table test2
(owner varchar2(30),
object_name varchar2(128),
object_id number,
object_id_2 number,
create_date date default sysdate);
alter table test add constraint test_pk primary key (owner, object_name, object_id,object_id_2);
alter table test2 add constraint test2_pk primary key (owner, object_name, object_id,object_id_2);
insert /*+ append */ into test select owner, object_name,object_id,1 ,sysdate from dba_objects where object_id is not null;
insert /*+ append */ into test select owner, object_name,object_id,2 ,sysdate from dba_objects where object_id is not null;
commit;
insert /*+ append */ into test select owner, object_name,object_id,3 ,sysdate from dba_objects where object_id is not null;
commit;
insert /*+ append */ into test select owner, object_name,object_id,4 ,sysdate from dba_objects where object_id is not null;
commit;
insert /*+ append */ into test select owner, object_name,object_id,5 ,sysdate from dba_objects where object_id is not null;
commit;
17:56:57 testuser@db>select count(*) from test;
COUNT(*)
----------
1141645
--actual sql to be made parallel:..this is to be converted to use dbms_parallel_execute packae
insert into test2 select owner, object_name,object_id,object_id_2 ,sysdate from test where object_id is not null;