Truncated incorrect DOUBLE value Solution

Source: Internet
Author: User
Tags mysql manual


Truncated incorrect DOUBLE value solution the project encountered the "1292 truncated incorrect double value" error when operating the MYSQL database VARCHAR field. The MYSQL manual says: Error: 1292 SQLSTATE: 22007 (ER_TRUNCATED_WRONG_VALUE)
Message: Incorrect % s value truncated: '% s' www.2cto.com what is incorrect % s value truncated? Is it not allowed to directly null or assign values directly. Think twice.

At last, I found some other possible problems on the Internet, but they are not exactly the same.

In other people's cases, "+" is often used to add strings incorrectly, rather than the library function "concat ". This method is used to add the field strings. But the key is that my problem is direct assignment instead of string connection.

Finally, we used the concat function: concat (Str, '') to solve the problem in disguise.
 

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.