Welcome to WuJiGu Developer Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.1k views
in Technique[技术] by (71.8m points)

oracle - Slow query execution in an empty table. (after deleting a large amount of inserts)

I have a table in an oracle database with 15 fields. This table had 3500000 inserts. I deleted them all.

delete
from table

After that, whenever I execute a select statement
I get a very slow response (7 sec) even though the table is empty. I get a normal response only in the case that I search according to an indexed field.

Why?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Tom Kyte has a good explanation of this issue:

http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:492636200346818072

It should help you understand deletes, truncates, and high watermarks etc.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to WuJiGu Developer Q&A Community for programmer and developer-Open, Learning and Share
...