Home  >  Article  >  Database  >  How to query how many records each table has in mysql

How to query how many records each table has in mysql

王林
王林Original
2020-10-16 09:37:227693browse

Mysql method to query how many records each table has: execute the [select table_name, table_rows from tables where TABLE_SCHEMA = 'name of database';] statement.

How to query how many records each table has in mysql

Mysql method to query how many records each table has

(Recommended tutorial: mysql video tutorial)

Execute the following SQL statement:

use information_schema;
select table_name,table_rows from tables where TABLE_SCHEMA = '数据库的名称' order by table_rows desc;

Related recommendations: mysql tutorial

The above is the detailed content of How to query how many records each table has in mysql. 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