info:mysql:calc_size

source: https://www.bggofurther.com/fr/2016/08/calculate-databasetable-size-in-mysql/

La taille de toutes les bases

SELECT table_schema "Database Name", SUM(data_length+index_length)/1024/1024
"Database Size (MB)"  FROM information_schema.TABLES GROUP BY table_schema;

La taille des tables d’une base spécifique

SELECT table_name "Table Name", table_rows "Rows Count", round(((data_length + index_length)/1024/1024),2) "Table Size (MB)" FROM information_schema.TABLES WHERE table_schema = "db_4";
  • info/mysql/calc_size.txt
  • Dernière modification : 2023/03/20 14:14
  • de radeff