I'm using WHERE XXX IN (SQL), so (SQL) must select only one Column
In this case I'm select some customer_id from a group, and those customer only belongs to that group only
WHERE `id_customer` IN(
SELECT g.`id_customer` // this must select *only one* column
FROM ps_customer_group AS g
Group By g.`id_customer`
Having COUNT(g.`id_customer`) = 1
AND g.`id_group`=3 // **- Unknown column 'g.id_group' in 'having clause'**
)
the raw data look like this, btw this is not the result

id_customerand searching for having count = 1. So it will return you more than one values.