Somebody already helped me with this query but I made an adaptation and I get a problem :
SELECT AVG(tyd.price) AS avg_price, COUNT(tyd.id_product)
i just want to add that this query :
SELECT * FROM tyd WHERE step = "1" GROUP BY tyd.id_product, tyd.id_marchand HAVING tyd.login = "user1@tyd.fr"
Has the same problem. Works when tyd.login = "user3" but not when an other user is ask...