SMF Database Error [SQL_BIG_SELECTS or MAX_JOIN_SIZE]

DATABASE ERROR

Code: [Select]
Database Error: The SELECT would examine more than MAX_JOIN_SIZE rows; check your WHERE and use SET SQL_BIG_SELECTS=1 or SET SQL_MAX_JOIN_SIZE=# if the SELECT is okay

How to fix the Error:

Find the Line in Load.php (inside the source directory)

Code: [Select]
Try to load it from the cache first; it’ll never get cached if the setting is off.

SMF 1.X

Paste this line after the above line

Code: [Select]
db_query(“SET SQL_BIG_SELECTS=1”, FILE, LINE);

SMF 2.X

Paste this line after the above line

Code: [Select]
$request = $smcFunc[‘db_query’](‘’, ‘SET SQL_BIG_SELECTS=1’,array());

Hope it will help all the admin, who are having this trouble for long time…

Thanks
Zen

Portal for Indian Community