开发者

SQL data execution plan

开发者 https://www.devze.com 2023-01-02 04:44 出处:网络
Does SELECT TOP 1000 * FROM TABLE return the same data execution plan as SELECT * FROM TABLE? Please also let me know if this should 开发者_如何学Pythonbe moved to ServerFault.

Does

SELECT TOP 1000 * FROM TABLE

return the same data execution plan as

SELECT * FROM TABLE?

Please also let me know if this should 开发者_如何学Pythonbe moved to ServerFault.

Thanks.


You can check for yourself. In SSMS, go to Query -> Include Actual Execution Plan

Then run your queries.

e.g. when I run:

SELECT TOP 10 * FROM sys.tables
SELECT * FROM sys.tables

They return different execution plans.

0

精彩评论

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

关注公众号