Querying An Int Column From Table That Also Stores Blob Column (Performance)
If you select an INT column from a table that also has a medium/large BLOB column (without selecting the BLOB column) will the query take longer than if the BLOB column was not there?
I am wondering if I should move the BLOB column to a separate table. Does the query duration depend mostly on the size (bytes) of a table or is it based mostly on the columns being selected?
I realize there are potentially a number of factors involved but I am asking in general terms.
Answer Answered by Jan Steinman in this comment.
If using innodb and an indexed INT column, I believe that query time is independent of whatever other columns may be in that table.
What will increase query time is if you are using a tool that loads the BLOB when it displays records. Many of them allow you to turn off loading of BLOB and TEXT fields.