开发者

Select Query Running slowly for a particular table

In my table, I have more than 300 records in a table.

If, for example, I run

select top 200 * from 开发者_Python百科tablename

it runs fast. But if I run

select top 301 * from tablename

It's executing for a long time.....

Also, I can't run the following query at all:

select * from tablename

...it is too slow...

I want to the delete the records after 301 in that table.


How wide is your table? What's the table definition look like?

If you have an identity column you could just run this:

delete from dbo.Table where TableID>301
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜