Compatibility problem of a MYSQL syntax (using count in queries) _ MySQL

Source: Internet
Author: User
Analysis on the compatibility of a MYSQL syntax (using count in queries) bitsCN.com simply uses count and more fields in queries.

Select count (id), id, name from table

It's embarrassing. my environment is 5.5, and the results can be obtained, but it won't work if I run it on the server.
Okay, an error is reported.

#1140-Mixing of GROUP columns (MIN (), MAX (), COUNT (),...) with no GROUP columns is illegal if there is no group by clause

In step 5. x can be used, but the values of other fields only obtain the first piece of information. well, I admit that this is a partial method and has no practical significance, it may be caused by a new beginner's unclear syntax structure.
Well, as a newbie, I am still wise to use the WAMP version switch function to switch over bitsCN.com.

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.