Re: Can't INSERT on diferent MySQL version
Posted by: Peter Brawley
Date: November 24, 2020 11:14AM

That's a coding error that IIRC MySQL used to forgive, but such forgiveness caused many other problems so it no longer does by default.

In 5.7 I think default sql_mode is ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION. I think you'll need to look at three stages of dealing with this problem ...

1 Shortterm fix: If you remove strict_trans_tables from the sql_mode setting, the coding error will raise a warning rather than an error.

2 Assuming that all your app's database ops have competent error handlers, you can ensure that it (i) handles such warnings in a user-friendly way and (ii) logs them.

3 Those logs will show you where you need to fix those bugs..

Options: ReplyQuote


Subject
Written By
Posted
Re: Can't INSERT on diferent MySQL version
November 24, 2020 11:14AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.