Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The statistics module seems to be relying on the MySQL facility whereby a column in a SELECT list, not referenced in a GROUP BY clause outputs the last value seen for that column within the groupings of the other fields. Postgres does not have this facility and instead rejects the query as invalid SQL.
Therefore, the select clauses which are retrieving the data for the individual sub pages under admin/log/hits all fail in Postgres.
Comment | File | Size | Author |
---|---|---|---|
#1 | statistics.patch0 | 2.98 KB | AlanChandler |
Comments
Comment #1
AlanChandler CreditAttribution: AlanChandler commentedI have included a patch to solve the problem - although it changes the functionality a bit (hence the new titles to the columns).
I can't easily see how to do the original functionality with valid SQL - but then I am no expert.
Comment #2
adrian CreditAttribution: adrian commentedI havent had time to look at this properly, but i am assigning this to myself.
Comment #3
Dries CreditAttribution: Dries commentedI committed this to HEAD. Thanks Alan.
Adrian: if the fix isn't right, please re-open this bug report and attach a proper patch.
Comment #4
(not verified) CreditAttribution: commented