Not a bug Server error from Usergroup Promotions

Mouth

Well-known member
Code:
Zend_Db_Statement_Mysqli_Exception: Mysqli prepare error: Operand should contain 1 column(s) - library/Zend/Db/Statement/Mysqli.php:77
Generated By: Unknown Account, 15 minutes ago
Stack Trace
#0 /var/www/netrider/library/Zend/Db/Statement.php(115): Zend_Db_Statement_Mysqli->_prepare('?????SELECT use...')
#1 /var/www/netrider/library/Zend/Db/Adapter/Mysqli.php(381): Zend_Db_Statement->__construct(Object(Zend_Db_Adapter_Mysqli), '?????SELECT use...')
#2 /var/www/netrider/library/Zend/Db/Adapter/Abstract.php(478): Zend_Db_Adapter_Mysqli->prepare('?????SELECT use...')
#3 /var/www/netrider/library/XenForo/Model.php(219): Zend_Db_Adapter_Abstract->query('?????SELECT use...', Array, 2)
#4 /var/www/netrider/library/XenForo/Model/User.php(327): XenForo_Model->fetchAllKeyed('?????SELECT use...', 'user_id')
#5 /var/www/netrider/library/XenForo/CronEntry/Trophy.php(32): XenForo_Model_User->getUsers(Array, Array)
#6 [internal function]: XenForo_CronEntry_Trophy::runTrophyCheck(Array)
#7 /var/www/netrider/library/XenForo/Model/Cron.php(356): call_user_func(Array, Array)
#8 /var/www/netrider/library/XenForo/Deferred/Cron.php(24): XenForo_Model_Cron->runEntry(Array)
#9 /var/www/netrider/library/XenForo/Model/Deferred.php(256): XenForo_Deferred_Cron->execute(Array, Array, 7.9999978542328, '')
#10 /var/www/netrider/library/XenForo/Model/Deferred.php(390): XenForo_Model_Deferred->runDeferred(Array, 7.9999978542328, '', false)
#11 /var/www/netrider/library/XenForo/Model/Deferred.php(335): XenForo_Model_Deferred->_runInternal(Array, NULL, '', false)
#12 /var/www/netrider/deferred.php(23): XenForo_Model_Deferred->run(false)
#13 {main}
Request State
array(3) {
  ["url"] => string(35) "http://netrider.net.au/deferred.php"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(4) {
    ["_xfRequestUri"] => string(34) "/admin.php?users/fred.12345/edit"
    ["_xfNoRedirect"] => string(1) "1"
    ["_xfToken"] => string(8) "********"
    ["_xfResponseType"] => string(4) "json"
  }
}

Background, and further information: http://xenforo.com/community/threads/usergroup-promotions-not-behaving.70184/
 
I don't think anything has changed in trophies for a while, though we did just have a report of this here: http://xenforo.com/community/threads/error-zend_db_statement_mysqli_exception.70082/#post-732502 Looking at the code, I don't really see why this could happen. Have you recently changed anything on your server?
That report looks very similar, if not the same.
Recent change (within the few days) has been 1.3RC1 to 1.3RC2 upgrade, and version upgrade/update for a couple of add-ons.
Here's very similar entry in teh server error log too ...
Code:
Zend_Db_Statement_Mysqli_Exception: Mysqli prepare error: Operand should contain 1 column(s) - library/Zend/Db/Statement/Mysqli.php:77
Generated By: Unknown Account, 58 minutes ago
Stack Trace
#0 /var/www/netrider/library/Zend/Db/Statement.php(115): Zend_Db_Statement_Mysqli->_prepare('?????SELECT use...')
#1 /var/www/netrider/library/Zend/Db/Adapter/Mysqli.php(381): Zend_Db_Statement->__construct(Object(Zend_Db_Adapter_Mysqli), '?????SELECT use...')
#2 /var/www/netrider/library/Zend/Db/Adapter/Abstract.php(478): Zend_Db_Adapter_Mysqli->prepare('?????SELECT use...')
#3 /var/www/netrider/library/XenForo/Model.php(219): Zend_Db_Adapter_Abstract->query('?????SELECT use...', Array, 2)
#4 /var/www/netrider/library/XenForo/Model/User.php(327): XenForo_Model->fetchAllKeyed('?????SELECT use...', 'user_id')
#5 /var/www/netrider/library/XenForo/CronEntry/UserGroupPromotion.php(32): XenForo_Model_User->getUsers(Array, Array)
#6 [internal function]: XenForo_CronEntry_UserGroupPromotion::runPromotions(Array)
#7 /var/www/netrider/library/XenForo/Model/Cron.php(356): call_user_func(Array, Array)
#8 /var/www/netrider/library/XenForo/Deferred/Cron.php(24): XenForo_Model_Cron->runEntry(Array)
#9 /var/www/netrider/library/XenForo/Model/Deferred.php(256): XenForo_Deferred_Cron->execute(Array, Array, 7.9999969005585, '')
#10 /var/www/netrider/library/XenForo/Model/Deferred.php(390): XenForo_Model_Deferred->runDeferred(Array, 7.9999969005585, '', false)
#11 /var/www/netrider/library/XenForo/Model/Deferred.php(335): XenForo_Model_Deferred->_runInternal(Array, NULL, '', false)
#12 /var/www/netrider/deferred.php(23): XenForo_Model_Deferred->run(false)
#13 {main}
Request State
array(3) {
  ["url"] => string(7) "http://"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(0) {
  }
}
Line #6 seems to change between runTrophyCheck and runPromotions

I may need FTP details to debug it though.
Happy to send through SSH logon details if you determine required. I am using v1.3RC2 and aware of its unsupported nature though.
 
Is this happening every time the trophy/promotion cron runs or is it random? Hopefully it's consistent.

Please submit a ticket via the customer area with FTP/SSH or similar details and an ACP account I can use to manually trigger these crons.
 
This was related to an add-on. I was only able to narrow it down to about 10 on the site in question, but hopefully he'll be able to identify it after disabling them or noting which ones were recently upgraded.
 
Back
Top Bottom