How to set a varchar to have unlimited length?
You can try using varchar(max)
VARCHAR can store upto 255 chars before MySQL 5.0.3 and 65,535 chars in 5.0.3 and later versions.
To store large data in Mysql database you can use
TEXT , MEDIUMTEXT , LONGTEXT
TEXT can store 65,535 characters (approx 64KB)
MEDIUMTEXT = 16,777,215 characters (approx 16 MB)
LONGTEXT = 4,294,967,295 chars (approx 4GB)