欢迎光临
我们一直在努力

MySQL Variables sql_select_limit 数据库 参数变量解释及正确配置使用

本站中文解释

sql_select_limit参数是MySQL服务器在执行查询时最多返回给客户端的行数限制。如果设置的值比查询返回的行数小,则MySQL服务器会终止后续查询执行。要设置sql_select_limit参数,可以打开MySQL服务器的配置文件my.cnf,在[mysqld]段落中添加如下行:

sql_select_limit=value

其中value为设置的最大行数,表示MySQL执行查询时最多返回多少行给客户端。完成配置后,需要重新启动MySQL服务器,让其生效。

官方英文解释

sql_select_limit

System Variable sql_select_limit
Scope Global, Session
Dynamic Yes
Type Integer
Default Value 18446744073709551615
Minimum Value 0
Maximum Value 18446744073709551615

The maximum number of rows to return from
SELECT statements. For more
information, see Using Safe-Updates Mode (–safe-updates).

The default value for a new connection is the maximum number
of rows that the server permits per table. Typical default
values are (232)−1 or
(264)−1. If you have changed
the limit, the default value can be restored by assigning a
value of DEFAULT.

If a SELECT has a
LIMIT clause, the LIMIT
takes precedence over the value of
sql_select_limit.

赞(0)
【声明】:本博客不参与任何交易,也非中介,仅记录个人感兴趣的主机测评结果和优惠活动,内容均不作直接、间接、法定、约定的保证。访问本博客请务必遵守有关互联网的相关法律、规定与规则。一旦您访问本博客,即表示您已经知晓并接受了此声明通告。