Working and searching large amounts of text

From what I understand, VARCHAR columns are stored in the row and TEXT columns aren’t. In reality how much does this affect performance? What are good practices for storing large amounts of text in MySQL. Specifically:

  1. If you’re not selecting TEXT columns, will you receive any hit in performance?
  2. If you had a small string stored both in TEXT and LARGETEXT, do they take up the same amount of memory (i.e. they aren’t like CHAR fields that are fixed in size)?
  3. On a FULLTEXT search, would having LARGETEXT when TEXT would do affect performance much? I’m assuming it won’t since the query is on the index, not the column (unless you’re selecting the column)
  4. On both LIKE and FULLTEXT search, is it better to have NULL over an empty string for rows with nothing to search?

Thanks.

  1. no, it will go faster
  2. i believe the answer is yes, they are truncated to fit the data
  3. you’re right, no
  4. i don’t think it makes a difference

Thanks again. :slight_smile: