• Expression #1 of ORDER BY clause is not in SELECT list, references column 'admin_lvk.oc_200_lj.int_val' which is not in SELECT list; this is incompatible with DISTINCT in query: SELECT DISTINCT SQL_CALC_FOUND_ROWS as id, h.rel as pid FROM cms3_hierarchy h, cms3_permissions p, cms3_hierarchy_relations hr, cms3_objects o LEFT JOIN cms3_object_content oc_200_lj ON AND oc_200_lj.field_id = '200' WHERE h.type_id IN (29) AND h.lang_id = '5' AND h.is_deleted = '0' AND h.is_active = '1' AND (p.rel_id = AND p.level & 1 AND p.owner_id IN(335)) AND = hr.child_id AND (hr.level <= 1 AND hr.rel_id = '943') AND h.obj_id = ORDER BY oc_200_lj.int_val DESC, h.ord ASC