Back to OStoreLocator Support

veron66770
veron66770

Hi , after installed the plugin i tried to access the setting page(ajaylulia/ostorelocator/branchhits) and came to this error

`SQLSTATE[42000]: Syntax error or access violation: 1055 Expression #3 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'cms.b.date_hits' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by (SQL: select s.id as storeid,name, date_hits, SUM(hits) as hits, DATE_ADD(date_hits, INTERVAL(1-DAYOFWEEK(date_hits)) DAY) as startdate, DATE_ADD(date_hits, INTERVAL(7-DAYOFWEEK(date_hits)) DAY) as enddate from `ajaylulia_ostorelocator_branch_hit` as `b` inner join `ajaylulia_ostorelocator_jsp_stores` as `s` on `b`.`store_id` = `s`.`id` where MONTH(date_hits) = 07 and YEAR(date_hits) = 2021 group by WEEK(date_hits), s.id)`

I search and found there is 2 solution which i already tried both

`SET GLOBAL sql_mode=(SELECT REPLACE(@@sql_mode,'ONLY_FULL_GROUP_BY',''));`

Below cause mysql server not able to start

`sql_mode = STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION`

Anyway to fix the issue? Please help

Last updated

1-1 of 1