aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/db/driver/mssqlnative.php
diff options
context:
space:
mode:
authorJakub Senko <jakubsenko@gmail.com>2018-06-18 20:42:16 +0200
committerMarc Alexander <admin@m-a-styles.de>2019-05-09 18:29:22 +0200
commitb4d4336ef4043a5b3381a9e70d3bbc6bc6732d07 (patch)
tree93bf9fdad16266be9504384e02c76d4b5a04cfa0 /phpBB/phpbb/db/driver/mssqlnative.php
parent5815d21427ce015e2e93d32071a79a1134d20536 (diff)
downloadforums-b4d4336ef4043a5b3381a9e70d3bbc6bc6732d07.tar
forums-b4d4336ef4043a5b3381a9e70d3bbc6bc6732d07.tar.gz
forums-b4d4336ef4043a5b3381a9e70d3bbc6bc6732d07.tar.bz2
forums-b4d4336ef4043a5b3381a9e70d3bbc6bc6732d07.tar.xz
forums-b4d4336ef4043a5b3381a9e70d3bbc6bc6732d07.zip
[ticket/12627] Add debug.sql_explain parameter
PHPBB3-12627
Diffstat (limited to 'phpBB/phpbb/db/driver/mssqlnative.php')
-rw-r--r--phpBB/phpbb/db/driver/mssqlnative.php7
1 files changed, 3 insertions, 4 deletions
diff --git a/phpBB/phpbb/db/driver/mssqlnative.php b/phpBB/phpbb/db/driver/mssqlnative.php
index a4dcac5966..ff37eaf1c2 100644
--- a/phpBB/phpbb/db/driver/mssqlnative.php
+++ b/phpBB/phpbb/db/driver/mssqlnative.php
@@ -123,8 +123,7 @@ class mssqlnative extends \phpbb\db\driver\mssql_base
{
global $cache;
- // EXPLAIN only in extra debug mode
- if (defined('DEBUG'))
+ if ($this->debug_sql_explain)
{
$this->sql_report('start', $query);
}
@@ -146,7 +145,7 @@ class mssqlnative extends \phpbb\db\driver\mssql_base
// reset options for next query
$this->query_options = array();
- if (defined('DEBUG'))
+ if ($this->debug_sql_explain)
{
$this->sql_report('stop', $query);
}
@@ -170,7 +169,7 @@ class mssqlnative extends \phpbb\db\driver\mssql_base
$this->open_queries[(int) $this->query_result] = $this->query_result;
}
}
- else if (defined('DEBUG'))
+ else if ($this->debug_sql_explain)
{
$this->sql_report('fromcache', $query);
}