title: How can i retrieve table names with rows count from specific database?
body: <p>How can i retrieve table names and count of rows for the specific database ?</p>
  
  <p>Like my database name is xyz. XYZ database I want fetch all the table and count of records for the specific tables.</p>
  
  <h2>Query</h2>
  
  <p>SELECT status.real_name AS "real_name", status.friendly_name AS "friendly_name", table_rows AS "quant_of_rows", ROUND((data_length + index_length)/1024/1024,2) AS "total_size_mb"  FROM information_schema.TABLES RIGHT JOIN table_status ON status.real_name = information_schema.TABLES.TABLE_NAME WHERE information_schema.TABLES.table_schema='database_name';</p>
  
  <p>This query displays 4 columns.</p>
  
  <ol>
  <li>original table name </li>
  <li>friendly table name </li>
  <li>records of table </li>
  <li>size of table</li>
  </ol>
  
  <p>I am getting problem with 3rd column. For InnoDB tables, the table_rows is only a rough estimate used in SQL optimization.</p>
  
  <p>Instead of table_rows can i use something like this ?</p>
  
  <pre><code>(select count(*) from information_schema.TABLES.TABLE_NAME) AS "Quant_of_Rows"
  </code></pre>
  
  <p>What are the other ways to get table_row for the database?</p>