-
-
Notifications
You must be signed in to change notification settings - Fork 825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix fatal error when full group by mysql mode enabled & selecting contacts #14331
Conversation
(Standard links)
|
CRM/Contact/BAO/Query.php
Outdated
@@ -4971,7 +4972,9 @@ public function getCachedContacts($cids, $includeContactIds) { | |||
$limit = ''; | |||
$query = "$select $from $where $groupBy $order $limit"; | |||
|
|||
return CRM_Core_DAO::executeQuery($query); | |||
$result = CRM_Core_DAO::executeQuery($query); | |||
CRM_Core_DAO::disableFullGroupByMode(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this doesn't look right @eileenmcnaughton
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
erm yep, fixed
Jenkins re test this please |
Unit test added here #14340 |
Unit test for FGB error in #14331
Jenkins re test this please |
Overview
Fixes a fatal error under some circumstances.
To replicate - on a server with full group by mysql mode enabled do a contact search. Select a contact & click next
Before
After
No fatal
Technical Details
Disable full group by when selecting contacts. Per the screen shot the query is pretty non-std & it makes sense fgb mode rejects it - this is our std solution
Comments