Ошибка базы данных.

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'WHERE `s_r`.`type` = 2' at line 4

SELECT `s_r`.`id`, `s_r`.`name`, `s_r`.`parent_id`, `o_c`.`qty` as count FROM (`services_rubrics` as s_r) LEFT JOIN `obj_counter` as o_c ON `o_c`.`srv_rubric` = `s_r`.`id` && o_c.srv_type = 2 && o_c.type = "srv" && o_c.subdomain_id = WHERE `s_r`.`type` = 2

Filename: /var/www/web/sites/subdomains/models/serv_subdomain_model.php

Line Number: 1221