phpMyAdmin 显示数据库表的负总记录

发布于 2024-10-03 11:00:39 字数 125 浏览 0 评论 0原文

当我检查数据库时,它显示一个表的负记录(例如-200,000),其他表的记录是静态的。

当我查看表格并返回摘要时,它随机更改为 -198,000 或 -220,000...它不是静态的。

可能会发生什么?

When I check my database, it's showing negative records for a table (e.g. -200,000), other tables' records are static.

When I view the table and go back to the summary, it changes randomly to -198,000, or -220,000... It's just not static.

What could be happening?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

无力看清 2024-10-10 11:00:39

这是一个老问题,但我遇到了一个问题,这篇文章是谷歌上出现的第一件事,所以我想我会提出正确的答案。

您会注意到所有“负 mysql 记录”问题都与大型表或数据库有关。这不是一个负号,它的~,意思是大约。基本上就是说有那么多记录。据我所知,一旦 phpMyAdmin 中任何表的记录超过 20,000 条,它就会显示出来。这也是提问者数量不断波动的原因,这并不准确。

This is an old question but one that I ran into and this post was the first thing to show up on google so I thought I would put the right answer up.

You'll notice that all of the "negative mysql records" questions are with large tables or databases. This isn't a negative sign its ~, which means approximately. It's basically saying that there's around that many records. As far as I can tell, it shows up once any table gets more than 20,000 records in it in phpMyAdmin. This is also why the askers numbers keep fluctuating, it's not exact.

林空鹿饮溪 2024-10-10 11:00:39

正如 Eric Strom 已经提到的那样,这是正确的,即 phpMyAdmin 的符号平均估计总行数。您始终可以删除该 ~ 符号或通过单击此数字获取其总行的精确值。这是我的
自己的表示例:

在此处输入图像描述

,点击以~号开头的数字后,您将得到重新计算后的总行数。

![在此输入图像描述

as Eric Strom already mention that, it is correct which is that sign mean estimated total row by phpMyAdmin. you can always get a rid of that ~ sign or get exact value of its total row by clicking this number. here it is on my
own table example :

enter image description here

and after click that number that started with ~ sign, you will get total row exactly after being re-calculated.

![enter image description here

扛起拖把扫天下 2024-10-10 11:00:39

转到 phpmyadmin

  1. 选择有问题的表,
  2. 从顶部的选项卡中选择“操作”,
  3. 查看“表维护”块下有哪些选项。我只需按顺序单击它们,让每个操作完成,然后看看问题是否仍然存在。
    每个操作旁边都有一个帮助按钮来解释它的作用。 (我打赌 FLUSH 应该可以解决你的问题)。

go to phpmyadmin

  1. select the problematic table
  2. choose "operations" from the tabs on the top
  3. look under the "table maintainance" block what options you have. I would simply click them all by order, let each operation finish, and see if problem remains.
    Each operation has a help button next to it to explain what it does. (My bet is that FLUSH should fix your problem).
寒冷纷飞旳雪 2024-10-10 11:00:39

如果 FLUSH 没有解决您的问题,请尝试对表进行碎片整理。当表包含数十亿行时,通常会出现表行数的这种变化。

PHP-Myadmin 总会有一些限制。

同时,您还可以触发查询“select count(id) from tableName”来获取确切的行数。

If FLUSH didn't solve your problem, try to de-fragment your table, This variations in numbers of table-rows usually occurs when table contains billions of rows.

There will be always some limitations in PHP-Myadmin.

And same time you can also fire a query "select count(id) from tableName" to get the exact number of rows.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文