MySQL table changed the code, statement execution on the error

Source: Internet
Author: User
I changed the form and field code from UTF8_GENERAL_CI to Utf8_unicode_ci, and I got an error.
Warning:mysql_num_rows (): supplied argument is not a valid MySQL result resource In/var/www/html/amazonnew/function/sale _import.class.php on line 29


Another question, what coding is better for saving national languages??


Reply to discussion (solution)

Why did you change it?

Utf8_general_ci is enough.

Utf8_general_ci has been adapted to the language of all countries! At least Japanese, English, Simplified Chinese, traditional Chinese are applicable

If you want to save the content that MySQL does not support, can do JSON encode to store, get time decode.

The error may not be due to a coding problem. You output the content returned by the Mysql_error () function. See what the specific error is?

Warning:mysql_num_rows (): supplied argument is not a valid MySQL result resource In/var/www/html/amazonnew/function/sale _import.class.php on line 29

This error message is due to query SQL execution failure.

Post your 29 lines of code

Now no error, thank you!

There's one more question, the second one.
Does UTF8_GENERAL_CI encoding support the world's major languages?

I want to save Japanese, French, English, German, simplified, traditional, Hindi, and some European languages!

Now accustomed to use UTF8_GENERAL_CI, generally create a database is generally chosen this, but for you to ask for the German and so the support is weaker than utf8_unicode_ci

With UTF8_GENERAL_CI, generally create a database to choose this

  • 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.