SELECT a.* FROM module_mod a INNER JOIN module_mod b ON a.id_mod = b.idmod_mod INNER JOIN module_mod c ON c.idmod_mod = b.id_mod INNER JOIN option_opt ON idmod_opt = c.id_mod INNER JOIN optionvalue_ova ON idopt_ova = id_opt INNER JOIN productoption_pop ON idova_pop=id_ova WHERE a.idmod_mod IS NULL AND idprd_pop = GROUP BY a.id_mod
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'GROUP BY a.id_mod' at line 1