啥也没写
分类: Mysql/postgreSQL
2022-02-11 09:35:40
mysql 5.7.8开始
max_execution_time applies to read-only SELECT statements.
mysql> show variables like 'max_execution_time';
+--------------------+-------+
| Variable_name | Value |
+--------------------+-------+
| max_execution_time | 10000 |
+--------------------+-------+
1 row in set (0.00 sec)
目前只支持select 语句
或者用如下用法 :
select /*+ max_execution_time(3000)*/ count(*) from t1 where status=0;