Text datatype
Posted: Sun Mar 30, 2003 11:49 pm
I had designed a MySQL table with one column defined as VarChar(250).
When I asked for some data to test with, I quickly realized that the column needed to be more like 3000 bytes. The Mascon client I often use would let me specify a text column, but not the max size.
Question is - if we add a row that simply has ABC - is this variable length, and am I just storing those three bytes plus whatever is needed to store the length of that field, or am I storing some huge - 2^16 or some such?
A little worried, as I could not specify a max size, but I gather that this is
calculated and taken care of by MySql...
thanks,
Phil J.
When I asked for some data to test with, I quickly realized that the column needed to be more like 3000 bytes. The Mascon client I often use would let me specify a text column, but not the max size.
Question is - if we add a row that simply has ABC - is this variable length, and am I just storing those three bytes plus whatever is needed to store the length of that field, or am I storing some huge - 2^16 or some such?
A little worried, as I could not specify a max size, but I gather that this is
calculated and taken care of by MySql...
thanks,
Phil J.