sql statements with equals vs in

后端 未结 2 1689
说谎
说谎 2020-12-16 09:14

Say that someone came up to you and said we\'re going to cut down the amount of SQL that we write by replacing equals with IN. The use would be both for single

2条回答
  •  爱一瞬间的悲伤
    2020-12-16 10:00

    The two will produce the same execution plan - either a table scan, index scan, or index seek, depending on if/how you have your table indexed.

    You can see for yourself - Displaying Graphical Execution Plans (SQL Server Management Studio) - See the section called "Using the Execution Plan Options".

提交回复
热议问题