SELECT p.product_id, p.sort_order, "1" AS match_filters, pp.sort_order FROM `oc_product` AS p INNER JOIN `oc_product_to_store` AS p2s ON (p2s.product_id = p.product_id) INNER JOIN `oc_bf_filter` AS f ON (p.product_id = f.product_id) INNER JOIN `oc_product_description` AS pd ON (pd.product_id = p.product_id) INNER JOIN `oc_product` AS pp ON (pp.product_id = p.product_id) WHERE p2s.store_id = '0' AND (pd.tag LIKE "%балетки%") AND pd.language_id = '1' AND pd.language_id = '1' AND p.status = '1' AND p.price > 0 AND p.quantity > 0 GROUP BY p.product_id HAVING match_filters = 1 ORDER BY pp.sort_order ASC LIMIT 0, 15Array ( [0] => Array ( [product_id] => 62995518 [sort_order] => 0 [match_filters] => 1 ) [1] => Array ( [product_id] => 62995547 [sort_order] => 0 [match_filters] => 1 ) [2] => Array ( [product_id] => 62995548 [sort_order] => 0 [match_filters] => 1 ) [3] => Array ( [product_id] => 62995549 [sort_order] => 0 [match_filters] => 1 ) [4] => Array ( [product_id] => 62995806 [sort_order] => 0 [match_filters] => 1 ) [5] => Array ( [product_id] => 62995809 [sort_order] => 0 [match_filters] => 1 ) [6] => Array ( [product_id] => 62995810 [sort_order] => 0 [match_filters] => 1 ) [7] => Array ( [product_id] => 62995544 [sort_order] => 1 [match_filters] => 1 ) )