Fix the problem: Incorrect integer value: ' for column ' id ' at row 1.

Source: Internet
Author: User

Error incorrect integer value: ' for column ' id ' at row 1 occurred while restoring a database backup using Navicat for MySQL;

Online search data found that more than 5 of the version if the null value should be write null
This problem generally appears on MySQL 5.x.

Using select version (), viewing,

I'm using mysql5.0.37, and the MySQL database version that created the backup is 5.6.

Official explained: "Learned that the new version of MySQL to insert a null value" bug,
To remove the default checked enable strict SQL mode when installing MySQL
So what if we install MySQL, the workaround is to change the configuration in MySQL My.ini

Find Sql-mode in My.ini,

default to Sql-mode= "Strict_trans_tables,no_auto_create_user,no_engine_substitution",

Modify it to sql-mode= "no_auto_create_user,no_engine_substitution" and restart MySQL
So if it is a virtual host or a space to do. It's best if you can get the space trader to help you change that.

If not, then you can only change the procedure. is a bit of a norm. Null value to write nulls

This problem was resolved, but there was also the "1062-duplicate entry ' 1 for key 1" problem when restoring the backup, as shown in the following figure:


Online also did not find the relevant information, and then recreated a backup, copied over to restore,

The problem is solved, and it is estimated that the error occurred during the creation of the backup due to network problems.


Reprint: https://blog.csdn.net/testcs_dn/article/details/39670421

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.