Welcome Guest, Not a member yet? Register   Sign In
MySQL - Issue with SELECT & GROUP BY [SOLVED]
#3

(11-29-2018, 06:49 AM)Pertti Wrote: I'm not entirely sure this will work, but try this
PHP Code:
$this->db->select("pages.*,GROUP_CONCAT('tags_name')"); 

Thanks for your fast reply ! 

So i tried your solution and it works, BUT when i echo the GROUP_CONCAT('tags_name'), it only displays "tags_name" or "tags_name,tags_name", the value is the field's name and NOT the value itself... Weird.

So instead of giving : "environment,technology,economy" it gives "tags_name,tags_name,tags_name"

Any idea how to fix it ? I tried to add "themes.*" in the SELECT, but it gives the same error as before (Expression #2 of SELECT bla bla)
Reply


Messages In This Thread
RE: MySQL - Issue with SELECT & GROUP BY - by Coool6 - 11-29-2018, 07:22 AM



Theme © iAndrew 2016 - Forum software by © MyBB