Jump to content

Product Options, MySQL Error Occured, 1104:


cb2004
 Share

Recommended Posts

One of my customers gets this error when trying to enter product options:

Product Options

MySQL Error Occured

1104: 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

QUERY = SELECT DISTINCT productId, name FROM cartcube_CubeCart_options_bot RIGHT JOIN cartcube_CubeCart_inventory ON product = productId ORDER BY name ASC

Any ideas?

Link to comment
Share on other sites

Around line 278 on /admin/products/options.php

Find this:

get slave products

$slaveProducts = $db->select("SELECT DISTINCT productId, name FROM ".$glob['dbprefix']."CubeCart_options_bot RIGHT JOIN ".$glob['dbprefix']."CubeCart_inventory ON product = productId ORDER BY name ASC");




Add this line before $slaveProducts:

$bigselects = $db->misc("SET sql_big_selects=1");



So it looks like this:




get slave products

$bigselects = $db->misc("SET sql_big_selects=1");

$slaveProducts = $db->select("SELECT DISTINCT productId, name FROM ".$glob['dbprefix']."CubeCart_options_bot RIGHT JOIN ".$glob['dbprefix']."CubeCart_inventory ON product = productId ORDER BY name ASC");

Should this be added to the release?

Link to comment
Share on other sites

  • 3 months later...

I have the following as well when I go to product options....

1104: 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

QUERY = SELECT DISTINCT productId, name FROM CubeCart_options_bot RIGHT JOIN CubeCart_inventory ON product = productId ORDER BY name ASC

I have tried the fix suggested to no avail, cleared cache and even rebooted. Any help would be appreciated

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...