Does the number of columns returned affect the speed of a query?

前端 未结 18 2119
既然无缘
既然无缘 2020-12-10 16:27

If I have two queries

SELECT Id, Forename, Surname
FROM Person
WHERE PersonName Like(‘%frank%’)

And

SELECT *
FROM Person
WH         


        
18条回答
  •  渐次进展
    2020-12-10 16:40

    If remember correctly from college (and its been awhile), selecting * is not prefered, but not that bad -- until you start joining. When you get into the relational alegbra of creating the joined tuples, every column adds to time, so I would definately avoid it if possible.

提交回复
热议问题