开发者

have truncate and drop index better performance than drop table, create tale and create index?

I have a simple question:

Scenario:

Whose Perfomance is better ?

1)

DROP INDEX -->
TRUNCATE TABLE --> 
AND THEN FILLUP DATA -->
AND THEN CREATE INDEX

2)

DROP TABLE -->
CREATE TABLE -->
FILLUP DATA-->
CREATE INDEX

I am using a t开发者_StackOverflowable with millinos of recods. Which of these queries would suit my needs best?


Between the two methods, populating the data and then creating the index will be 99% of the time it takes to do the operation, I wouldn't worry that much if truncate or drop is faster after all both are not fully logged operations


The only real answer here is to try it and see - I expect that there will be very little difference in performance.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜