码迷,mamicode.com
首页 > 数据库 > 详细

navicat查看mysql数据表记录数不断变化

时间:2014-08-27 09:17:47      阅读:330      评论:0      收藏:0      [点我收藏+]

标签:style   http   使用   io   for   ar   数据   html   sp   

在使用navicat进行数据库管理的时候,在查看表对象的时候会发现,每次刷新,数据表的记录数不断变化,尤其是大表。

对于100万的数据经常会显示九十几万,当然通过count(*)出来的数据是正确的。

非常疑惑,查了一下资料,原来和存储引擎有关。官方说明:

The number of rows. Some storage engines, such as MyISAM, store the exact count. For other storage engines, such as InnoDB, this value is an approximation, and may vary from the actual value by as much as 40 to 50%. In such cases, use SELECT COUNT(*) to obtain an accurate count.
在myisam这种不支持事务的引擎中,这个值是精确的,在innodb这种支持事务的引擎中,是估算的。
https://dev.mysql.com/doc/refman/5.1/en/show-table-status.html

navicat查看mysql数据表记录数不断变化

标签:style   http   使用   io   for   ar   数据   html   sp   

原文地址:http://www.cnblogs.com/jeffreynet/p/3938650.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!