The tag has no usage guidance.

learn more… | top users | synonyms

1
vote
1answer
73 views

MySQL GROUP_CONCAT Query, is there a better way?

I have the below Data / Query. Is this really the most efficient way of doing this? As it seems like a lot of work to get the result. I've tried reducing it / combining the parts but this is the ...
0
votes
1answer
26 views

MySQL group concatenation - creation of insert statement on temp table

I have a temporary table TEST_GROUP, from where I'm working its data to fill another one. From this table, giving the example in the picture, my expected result is to group these three rows, so I ...
0
votes
1answer
88 views

Why group_concat and SQL_CALC_FOUND_ROWS do not work with each other?

I have following query which contain group_concat and SQL_CALC_FOUND_ROWS together as I want result + total no. of records present in it. SELECT SQL_CALC_FOUND_ROWS GROUP_CONCAT(ca.id) FROM ...
1
vote
0answers
22 views

Mysql trigger with group_concat

I'm trying to create insert and update triggers with SELECT GROUP_CONCAT request on one of the fields; This select query perfectly works, when I trying it in console, but trigger saves only first ...
1
vote
0answers
637 views

Duplicate GROUP_CONCAT values

Writing a plugin for Wordpress using a custom post type and an additional alias table to hold repetition of the post events. The problem comes with duplicate post meta values. wp_post_meta table: ...
1
vote
0answers
1k views

How can I join one to one to (many to one) without using group_concat

I have a table structure as follows: -- -- Table structure for table `emails` -- CREATE TABLE IF NOT EXISTS `emails` ( `ID` int(5) NOT NULL AUTO_INCREMENT, `email` varchar(255) COLLATE ...
0
votes
0answers
9 views

How to COUNT MySQL results when I use “GROUP_CONCAT” and “HAVING” in the query?

So I have a MySQL query that I want to count. Originally I use wordpress' get_results("") but I also need to count the total in a different query, because in my original query I LIMIT the results to ...