Некорректный запрос к БД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 'AND brand != 0' at line 1 SELECT DISTINCT brand FROM gys_katalog WHERE category = AND brand != 0