Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-20732

Tags (Categories) completely broken in 4.7.20 on Ubuntu 16.04 LTS

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: 4.7.20
    • Fix Version/s: None
    • Component/s: Core CiviCRM
    • Labels:
      None
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding
    • Verified?:
      No

      Description

      I've just clean installed CiviCRM 4.7.20 on Ubuntu 16.04 LTS (with latest WordPress, but I think that's irrelevant) and tags seem to be completely broken. If I click the Tags (Categories) item in the Configuration Checklist I just get an error message "Sorry but we are not able to provide this at the moment". Looking at the error log (extract below), it's pretty obvious this is a well-known problem due to the change of the default "sql_mode=only_full_group_by" setting last year in MySQL. The workaround is to change that setting, but it's there to prevent non-deterministic behaviour and I'd rather not impose that on all my sites.

      I couldn't find an existing bug report for this, but as I say it's a well-known problem so if it's a duplicate I apologise. I don't use tags as it happens but anyone who does will probably regard this as a major bug when they upgrade. Ubuntu is a pretty popular OS and earlier LTS versions run unsupported PHP versions so I'd say this is fairly urgent.

      Jun 14 00:52:27 [info] $Fatal Error Details = Array
      (
      [callback] => Array
      (
      [0] => CRM_Core_Error
      [1] => handle
      )

      [code] => -1
      [message] => DB Error: unknown error
      [mode] => 16
      [debug_info] => SELECT tag.*, child.id AS child, COUNT(et.id) as usages
      FROM civicrm_tag tag
      LEFT JOIN civicrm_entity_tag et ON et.tag_id = tag.id
      LEFT JOIN civicrm_tag child ON child.parent_id = tag.id
      WHERE tag.is_tagset <> 1 AND tag.parent_id IS NULL
      GROUP BY tag.id
      ORDER BY tag.name nativecode=1055 ** Expression #12 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'beechesit.child.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
      [type] => DB_Error
      [user_info] => SELECT tag.*, child.id AS child, COUNT(et.id) as usages
      FROM civicrm_tag tag
      LEFT JOIN civicrm_entity_tag et ON et.tag_id = tag.id
      LEFT JOIN civicrm_tag child ON child.parent_id = tag.id
      WHERE tag.is_tagset <> 1 AND tag.parent_id IS NULL
      GROUP BY tag.id
      ORDER BY tag.name nativecode=1055 ** Expression #12 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'beechesit.child.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by
      [to_string] => [db_error: message="DB Error: unknown error" code=-1 mode=callback callback=CRM_Core_Error::handle prefix="" info="SELECT tag.*, child.id AS child, COUNT(et.id) as usages
      FROM civicrm_tag tag
      LEFT JOIN civicrm_entity_tag et ON et.tag_id = tag.id
      LEFT JOIN civicrm_tag child ON child.parent_id = tag.id
      WHERE tag.is_tagset <> 1 AND tag.parent_id IS NULL
      GROUP BY tag.id
      ORDER BY tag.name nativecode=1055 ** Expression #12 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'beechesit.child.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by"]
      )

       

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                philmck Phil McKerracher
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: