Inserting data with a SQL query and insert into command is taking forever

60 views Asked by At

I'm working on Oracle using Toad and I have a problem: I have a SQL query written on with syntax. And the query is quite long, but it returns the first 500 rows in 30 seconds, also export to Excel is quick and it takes 1 minute for all records.

But when I try to insert data with "insert into", the query doesn't manage to insert that data; I cancelled it after 20 minutes.

The table where I'm trying to insert into is empty.

Does anyone have any suggestions?

For now the quickest way for me to insert it is exporting whole data and then importing excel into table...But I'm not fan of that

1

There are 1 answers

1
Smeks On

Guy thank you all for answers...The problem was that index was created wrong.