search

Home  >  Q&A  >  body text

Is there any difference in storage between MySQL, VARCHAR(1000) and TEXT (purpose: to store long strings)?

Actual Phenomenon

  1. Look forward to understanding the difference between VARCHAR/TEXT when storing large strings

  2. How to choose the type

  3. Understanding that TEXT will generate an intermediate virtual table

按照文档说明, VARCHAR(65536) --> 6KB --> 能存储足够大的字符串了

Expected Phenomenon

  1. Experience in data type selection (especially large strings)

PHP中文网PHP中文网2833 days ago1602

reply all(1)I'll reply

  • 过去多啦不再A梦

    过去多啦不再A梦2017-05-18 10:58:22

    Greater than varchar (255) becomes tinytext
    Greater than varchar (500) becomes text
    Greater than varchar (20000) becomes mediumtext

    reply
    0
  • Cancelreply