MySQL includes a COUNT()
function, which allows you to find out how many rows would be returned from a query. This function is part of the SQL standard, and it can be used with most relational database management systems.
The COUNT()
function can also be used to affect the results of a query if required, for example, by only returning those results that have a row count greater than a given amount.
This article contains examples of COUNT()
usage in MySQL.