Home  >  Article  >  Database  >  How to Get the Row Count in a MySQL Table?

How to Get the Row Count in a MySQL Table?

Barbara Streisand
Barbara StreisandOriginal
2024-11-06 02:55:02390browse

How to Get the Row Count in a MySQL Table?

Get Row Count in MySQL

Q: Which MySQL command should be used to determine the number of records in a table?

A: The following command will provide the row count for a specified table:

SELECT COUNT(*) FROM fooTable;

This query counts the number of rows in the fooTable table.

For more information, refer to the official MySQL documentation.

The above is the detailed content of How to Get the Row Count in a MySQL Table?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn