View Full Version : [vB 4.1.3+] Get rid of one query per page with a simple configuration change

07 May 2011, 11:12
If you are running vBulletin 4.1.3+ and you do not have set a Server SQL Mode (http://dev.mysql.com/doc/refman/5.1/en/server-sql-mode.html) you can get rid of one query on ervery page by adding

$config['Database']['no_force_sql_mode'] = true;

to your config.php

To verify that no mode is set run

SELECT @@GLOBAL.sql_mode;
SELECT @@SESSION.sql_mode;

If both queries give empty results no mode is set and you can safely add the configuration setting.

07 May 2011, 15:49
great tip - thanks for sharing!

11 May 2011, 21:15
great tip - thanks for sharing!

Ditto ;).

26 Jun 2011, 18:24
Where in AdminCP does it say set Server SQL Mode?

26 Jun 2011, 21:32
Nowhere. You can check by running the above query.

26 Jun 2011, 21:41
Awesome! Thanks!

--------------- Added 1309123130 at 1309123130 ---------------

Would it be possible to make this a plugin versus editing the config.php file?

30 Jun 2011, 21:44
Running the check above i get the return
@@GLOBAL.sql_mode; @@SESSION.sql_mode; So am i advised not to use this edit?

Thanks just wanted to be double sure