使用LIMIT时的phpMyAdmin Hanngs [英] phpMyAdmin Hanngs when using LIMIT

查看:90
本文介绍了使用LIMIT时的phpMyAdmin Hanngs的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有phpMyAdmin 4.8.3,我每天都会用它来查询主数据库表. 今天,我试图:

I have phpMyAdmin 4.8.3 I use it everyday to query the main db table. Today I tried to:

SELECT * FROM table WHERE list_id = 1227 LIMIT 2640

,它会一直加载,直到页面无响应"为止 我每天都使用它,没有任何问题.这只是现在,并且仅当我不使用LIMIT时才使用LIMIT,即使我使用了很多参数和ORDER BY RAND()

and it keeps loadding until "Page Unresponsive" I use it daily with no problems. It's just now and ONLY with LIMIT if I don't use LIMIT it works just fine even if I use many arguments and ORDER BY RAND()

推荐答案

如果在查询中未使用LIMIT,则PHPMyAdmin会自行设置一个限制.默认情况下,每页30行(在旧版本中);在较新的版本中,每页25行.它还提供了一个下拉菜单,用于将每页的行数最多更改为 500 (有时会崩溃,因为500行是要在一页中呈现的大量数据).

If you do not use LIMIT in a query, PHPMyAdmin puts a Limit on its own. By default it is 30 rows per page (in older versions); in newer versions, it is 25 rows per page. It also provides a dropdown to change the number of rows per page upto 500 (this can crash sometimes, as 500 rows is a lot of data to render in one page).

现在,如果您在查询中使用显式的Limit子句;它将使用您定义的值.但是,尝试在单个网页中呈现 2640 行是非常高的数目.通常,它会导致您的浏览器崩溃,并尝试加载大量数据.试想一下,您将需要进行垂直滚动才能到达页面底部.而且,由于检索到的数据包非常大,它也会增加MySQL服务器上的负载.

Now, if you use a explicit Limit clause in the query; it will use your defined value. However, trying to render 2640 rows in a single web page is very high number. It will generally crash your browser, trying to load a lot of data. Just imagine the vertical scrolling you will be needed to do, to get to the bottom of the page. Moreover, it will increase load on your MySQL server as well, due to very high data packet being retrieved.

这篇关于使用LIMIT时的phpMyAdmin Hanngs的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆