控制变量法-初中物理-Nobel Lecture, December 12, 1929-php执行SET GLOBAL connect_timeout=2效果

Posted rsapaper

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了控制变量法-初中物理-Nobel Lecture, December 12, 1929-php执行SET GLOBAL connect_timeout=2效果相关的知识,希望对你有一定的参考价值。

 

 1     $link = mysqli_connect("localhost", "wu", "wp", "wdb");
 2     $sql = \'SET GLOBAL  connect_timeout=2\';
 3     mysqli_query($link, $sql);
 4 
 5     ini_set(\'memory_limit\', \'-1\');
 6     $sql =\'ww\';
 7 $ww =0;
 8     if ($result = mysqli_query($link, $sql)) {
 9         while ($row = mysqli_fetch_assoc($result)) {
10             echo \'<br>\',$ww,\'--\'.time();
11             $ww++;
12         }
13         mysqli_free_result($result);
14     }
15 die();

 

 

 1     $link = mysqli_connect("localhost", "wu", "wp", "wdb");
 2     //$sql = \'SET GLOBAL  connect_timeout=2\';
 3     //mysqli_query($link, $sql);
 4 
 5     ini_set(\'memory_limit\', \'-1\');
 6     $sql =\'ww\';
 7 $ww =0;
 8     if ($result = mysqli_query($link, $sql)) {
 9         while ($row = mysqli_fetch_assoc($result)) {
10             echo \'<br>\',$ww,\'--\'.time();
11             $ww++;
12         }
13         mysqli_free_result($result);
14     }
15 die();

 

 

 

SHOW VARIABLES LIKE \'%out%\';

SET GLOBAL  connect_timeout=31536000;
SHOW VARIABLES LIKE \'%out%\';

SET GLOBAL  connect_timeout=2;
SHOW VARIABLES LIKE \'%out%\';

 

 

Navicat

\'ww\'

 

 

 

root账户 用php、Navicat、\\MySQL\\bin\\mysql.exe 执行 

SET GLOBAL  connect_timeout=420


影响的是每一个database,尽管php连接的是指定的某个库,Navicat是某个库的查询窗口,shell-mysql.exe USE w;

 

 

以上是关于控制变量法-初中物理-Nobel Lecture, December 12, 1929-php执行SET GLOBAL connect_timeout=2效果的主要内容,如果未能解决你的问题,请参考以下文章

MSF利用ms17_010实验

The 2018 Nobel prizesThe Nobel prize for economics is awarded for work on the climate and economic g

牛顿法及其收敛性

SQLZOO练习二--SELECT from Nobel Tutorial

初中物理思维导图,大脑的开发工具

SELECT from Nobel Tutorial