Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Select from dblink

669768Feb 24 2012 — edited Feb 28 2012
Database: 11g
I have written a dynamic sql for
insert into local_table(col1, col2..) select col1, col2....from remote_table@dblink
But this is running forever.

My DBA suggested me to create a temp table as select from remote_table and insert into local_table from temp_table, like this.

create temp_table as select col1, col2.. from remote_table@dblink;
insert into local_table(col1, col2..) select col1, col2....from temp table;
Both are dynamic sqls.

The DBA suggested method is running very fast than my original method.

Does anybody know why the direct insert from dblink is running very slow, compared to the create table as select from dblink ?

Thanks in Advance.
Karbi
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 27 2012
Added on Feb 24 2012
13 comments
14,228 views