How do you alter a MySQL table to make a column nullable?

Do this:

ALTER TABLE mytable MODIFY mycolumn VARCHAR(255);

Ps. You have to know what the original type is.

Reference:

https://stackoverflow.com/questions/212939/how-do-i-modify-a-mysql-column-to-allow-null

 

Tags

Share this article

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to Top