Should I disable MySQL strict mode?

Validate the data before inserting it into your database. If a string is too big to fit in your table, either your column is too narrow, or the data is invalid. You need to decide whether you truncate it before storing it, do some error reporting, or both.

Do not turn off the safety features of your DBMS, that’s the completely wrong thing to do.

Leave a Comment