drop table tab1 purge;
create table tab1(col1 int);
insert into tab1 values(1);
insert into tab1 values(2);
insert into tab1 values(3);
commit;
select * from tab1;
!rm -rf ext_dmp_1.dmp ext_dmp_2.dmp
drop table ext_dmp;
CREATE TABLE ext_dmp
ORGANIZATION EXTERNAL
(
TYPE ORACLE_DATAPUMP
DEFAULT DIRECTORY ORA_DIR
LOCATION ('ext_dmp_1.dmp')
)
AS SELECT * FROM tab1 WHERE col1 < 2;
drop table ext_dmp;
CREATE TABLE ext_dmp
ORGANIZATION EXTERNAL
(
TYPE ORACLE_DATAPUMP
DEFAULT DIRECTORY ORA_DIR
LOCATION ('ext_dmp_2.dmp')
)
AS SELECT * FROM tab1 WHERE col1 >= 2;
drop table ext_dmp_all;
CREATE TABLE ext_dmp_all
(
COL1 NUMBER
)
ORGANIZATION EXTERNAL
(
TYPE ORACLE_DATAPUMP
DEFAULT DIRECTORY ORA_DIR
LOCATION ('ext_dmp_1.dmp','ext_dmp_2.dmp')
);
select * from tab1;
select * from ext_dmp_all;