Hi guys.
There is something that is really unclear in a php book I have been learning from.
I have been learning about the different data type that you can use in mysql (such as CHAR, VARCHAR, INT, TINYINT,, etc, etc).
The one thing that has confused the hell out of me is the following paragraph:
With the character types — CHAR , VARCHAR , TEXT , and so on — the amount you can store may be less
than the maximum shown, depending on the character set used. For example, the UTF - 8 (Unicode)
character set commonly uses up to 3 bytes per character, so a VARCHAR field may only be able to store up
to 21,844 UTF - 8 characters.
Now taking this paragraph into account, it sounds like I should treat each of the data types (in mysql) as only being able to hold one 3rd of what it states in the book I am reading.
For example, it states in my book that 'CHAR' holds between 0-255 characters. But taking the above extract (paragraph) into account, should I treat it as 0-85 characters instead (to be on the safe side)?
Paul.