Export & Import
I have two tables STAT1 and STAT2.
I truncated STAT2. I need to import data from STAT1.
So, I exported table STAT1 to STAT1.dmp. (with data=yes and compress extents=yes)
Now I need to import from STAT.dmp to STAT2 with a condition like the following.
INSERT into STAT2 AS SELECT * FROM STAT1.dmp WHERE CURRENCY_TYPE_CD = 0 OR (ISO_CURRENCY_CD= '002' AND CURRENCY_TYPE_CD= 1)
How do I do this with imp? Or is there a sql statement I could run. Thanks.
why not just:
insert into STAT2
select * from STAT1
I do not think you can select from .dmp file,
which is only readable by imp. imp only imports into same table name,
in your case, it is STAT1.
You can NOT seletivly import data, I sure hope you did not truncate first!
You can try to limit your EXPORT with the *query* clause.
Or just do as sysdba said, depending on the table size.
I remember when this place was cool.
Do as sysdba has said. Plus u can add where condition for selective data.
Click Here to Expand Forum to Full Width