Page 1 of 1

Group_Concat Producing Duplicates

PostPosted: Thu Jun 20, 2019 1:35 am
by shock3
My query is producing some duplicates/repeats, but it isn't in each line. Some work correctly.
Group_concat.JPG
Group_concat.JPG (21.26 KiB) Viewed 405 times
I've checked to see if I have multiple entries in different tables that could cause this.
SQL.JPG


Thanks in advance!

Re: Group_Concat Producing Duplicates

PostPosted: Thu Jun 20, 2019 7:50 pm
by UnklDonald418
Since you didn't upload a sample database we can only guess what the problem might be.
In my tests
Code: Select all   Expand viewCollapse view
GROUP_CONCAT(' ', "Offer")
generates an error in HSQL which indicates you are using a different back end.
In my tests using HSQL
Code: Select all   Expand viewCollapse view
GROUP_CONCAT(DISTINCT "Offer" ORDER BY "Offer" SEPARATOR ' ')
eliminated duplicates.