The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End Long String in PHPMYSQL Reply To: Long String in PHPMYSQL


i want to add up to 50,000 words…

First, MySQL doesn’t count “words.” It counts bytes. If you’re talking about ASCII characters (e.g., the English alphabet and other characters that can be found on a typical US keyboard), then each character is one byte. Characters in other languages can be between one and four bytes apiece.

For 50,000 words, I would guess you would need to use the LONGTEXT type. MySQL’s MEDIUMTEXT type holds about 16MB, while LONGTEXT can support up to 4GB.