SHOW TABLES LIKE 'cms3_objects' SHOW TABLES LIKE 'cms3_object_types' SELECT name FROM `cms3_objects` where type_id = (SELECT id FROM `cms3_object_types` where guid='ip-blacklist') SELECT id, host, is_default, default_lang_id FROM cms3_domains SELECT id, host FROM cms3_domain_mirrows WHERE rel = '1' SELECT id, prefix, is_default, title FROM cms3_langs ORDER BY id SELECT id, name, filename, type, title, domain_id, lang_id, is_default FROM cms3_templates SELECT id FROM cms3_hierarchy WHERE is_default = '1' AND is_deleted='0' AND is_active='1' AND lang_id = '1' AND domain_id = '1' SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '43' AND o.id = h.obj_id SELECT `id`, `name`, `title`, `ext` FROM `cms3_hierarchy_types` ORDER BY `name`, `ext` SELECT `id` FROM `cms3_objects` WHERE `guid` = 'users-users-15' SELECT `id` FROM `cms3_objects` WHERE `guid` = 'system-supervisor' SELECT `id` FROM `cms3_objects` WHERE `guid` = 'system-guest' SELECT o.name, o.type_id, o.is_locked, o.owner_id, o.guid as `guid`, t.guid as `type_guid` FROM cms3_objects `o`, cms3_object_types `t` WHERE o.id = '13' and o.type_id = t.id SELECT name, parent_id, is_locked, is_guidable, is_public, hierarchy_type_id, sortable, guid FROM cms3_object_types WHERE id = '24' SELECT ofg.id as groupId, cof.id, cof.name, cof.title, cof.is_locked, cof.is_inheritable, cof.is_visible, cof.field_type_id, cof.guide_id, cof.in_search, cof.in_filter, cof.tip, cof.is_required, cof.sortable, cof.is_system, cof.restriction_id FROM cms3_object_field_groups ofg, cms3_fields_controller cfc, cms3_object_fields cof WHERE ofg.type_id = '24' AND cfc.group_id = ofg.id AND cof.id = cfc.field_id ORDER BY ofg.ord ASC, cfc.ord ASC SELECT id, name, title, type_id, is_active, is_visible, is_locked, ord FROM cms3_object_field_groups WHERE type_id = '24' ORDER BY ord ASC SELECT id, name, data_type, is_multiple, is_unsigned FROM cms3_object_field_types ORDER BY name ASC SELECT field_id, int_val, varchar_val, text_val, rel_val, tree_val, float_val FROM cms3_object_content WHERE obj_id = '13' SELECT COUNT(cp.allow) FROM cms_permissions cp WHERE method IS NULL AND (cp.owner_id = '13') AND cp.allow IN (1, 2) GROUP BY module SELECT cp.method, MAX(cp.allow) FROM cms_permissions cp WHERE module = 'content' AND (cp.owner_id = '13') GROUP BY module, method SELECT BIT_OR(cp.level) FROM cms3_permissions cp WHERE rel_id = '43' AND (cp.owner_id = '13') SELECT o.name, o.type_id, o.is_locked, o.owner_id, o.guid as `guid`, t.guid as `type_guid` FROM cms3_objects `o`, cms3_object_types `t` WHERE o.id = '394' and o.type_id = t.id SELECT name, parent_id, is_locked, is_guidable, is_public, hierarchy_type_id, sortable, guid FROM cms3_object_types WHERE id = '50' SELECT ofg.id as groupId, cof.id, cof.name, cof.title, cof.is_locked, cof.is_inheritable, cof.is_visible, cof.field_type_id, cof.guide_id, cof.in_search, cof.in_filter, cof.tip, cof.is_required, cof.sortable, cof.is_system, cof.restriction_id FROM cms3_object_field_groups ofg, cms3_fields_controller cfc, cms3_object_fields cof WHERE ofg.type_id = '50' AND cfc.group_id = ofg.id AND cof.id = cfc.field_id ORDER BY ofg.ord ASC, cfc.ord ASC SELECT id, name, title, type_id, is_active, is_visible, is_locked, ord FROM cms3_object_field_groups WHERE type_id = '50' ORDER BY ord ASC SELECT field_id, int_val, varchar_val, text_val, rel_val, tree_val, float_val FROM cms3_object_content WHERE obj_id = '394' SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '43' ORDER BY id SELECT BIT_OR(cp.level) FROM cms3_permissions cp WHERE rel_id = '38' AND (cp.owner_id = '13') SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '38' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '38' ORDER BY id SELECT o.name, o.type_id, o.is_locked, o.owner_id, o.guid as `guid`, t.guid as `type_guid` FROM cms3_objects `o`, cms3_object_types `t` WHERE o.id = '389' and o.type_id = t.id SELECT field_id, int_val, varchar_val, text_val, rel_val, tree_val, float_val FROM cms3_object_content WHERE obj_id = '389' SELECT BIT_OR(cp.level) FROM cms3_permissions cp WHERE rel_id = '24' AND (cp.owner_id = '13') SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '24' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '24' ORDER BY id SELECT o.name, o.type_id, o.is_locked, o.owner_id, o.guid as `guid`, t.guid as `type_guid` FROM cms3_objects `o`, cms3_object_types `t` WHERE o.id = '375' and o.type_id = t.id SELECT name, parent_id, is_locked, is_guidable, is_public, hierarchy_type_id, sortable, guid FROM cms3_object_types WHERE id = '111' SELECT ofg.id as groupId, cof.id, cof.name, cof.title, cof.is_locked, cof.is_inheritable, cof.is_visible, cof.field_type_id, cof.guide_id, cof.in_search, cof.in_filter, cof.tip, cof.is_required, cof.sortable, cof.is_system, cof.restriction_id FROM cms3_object_field_groups ofg, cms3_fields_controller cfc, cms3_object_fields cof WHERE ofg.type_id = '111' AND cfc.group_id = ofg.id AND cof.id = cfc.field_id ORDER BY ofg.ord ASC, cfc.ord ASC SELECT id, name, title, type_id, is_active, is_visible, is_locked, ord FROM cms3_object_field_groups WHERE type_id = '111' ORDER BY ord ASC SELECT field_id, int_val, varchar_val, text_val, rel_val, tree_val, float_val FROM cms3_object_content WHERE obj_id = '375' SELECT hr.child_id, h.rel, cp.level FROM cms3_hierarchy_relations hr, cms3_permissions cp, cms3_hierarchy h WHERE hr.rel_id IS NULL AND h.id = hr.child_id AND h.domain_id = '1' AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND h.is_visible = '1' AND (cp.rel_id = h.id AND (cp.owner_id = '13') AND cp.level > 0) AND hr.level <= '1' ORDER BY hr.level, h.ord SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '25' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '26' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '27' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '28' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '30' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '53' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '25' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '25' ORDER BY id SELECT level FROM cms3_hierarchy_relations WHERE child_id = 25 SELECT hr.child_id, h.rel, cp.level FROM cms3_hierarchy_relations hr, cms3_permissions cp, cms3_hierarchy h WHERE hr.rel_id = '25' AND h.id = hr.child_id AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND h.is_visible = '1' AND (cp.rel_id = h.id AND (cp.owner_id = '13') AND cp.level > 0) AND hr.level <= '1' ORDER BY hr.level, h.ord SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '26' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '26' ORDER BY id SELECT level FROM cms3_hierarchy_relations WHERE child_id = 26 SELECT hr.child_id, h.rel, cp.level FROM cms3_hierarchy_relations hr, cms3_permissions cp, cms3_hierarchy h WHERE hr.rel_id = '26' AND h.id = hr.child_id AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND h.is_visible = '1' AND (cp.rel_id = h.id AND (cp.owner_id = '13') AND cp.level > 0) AND hr.level <= '1' ORDER BY hr.level, h.ord SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '31' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '32' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '33' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '34' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '35' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '36' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '37' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '27' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '27' ORDER BY id SELECT level FROM cms3_hierarchy_relations WHERE child_id = 27 SELECT hr.child_id, h.rel, cp.level FROM cms3_hierarchy_relations hr, cms3_permissions cp, cms3_hierarchy h WHERE hr.rel_id = '27' AND h.id = hr.child_id AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND h.is_visible = '1' AND (cp.rel_id = h.id AND (cp.owner_id = '13') AND cp.level > 0) AND hr.level <= '1' ORDER BY hr.level, h.ord SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '54' AND o.id = h.obj_id SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '28' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '28' ORDER BY id SELECT level FROM cms3_hierarchy_relations WHERE child_id = 28 SELECT hr.child_id, h.rel, cp.level FROM cms3_hierarchy_relations hr, cms3_permissions cp, cms3_hierarchy h WHERE hr.rel_id = '28' AND h.id = hr.child_id AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND h.is_visible = '1' AND (cp.rel_id = h.id AND (cp.owner_id = '13') AND cp.level > 0) AND hr.level <= '1' ORDER BY hr.level, h.ord SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '30' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '30' ORDER BY id SELECT level FROM cms3_hierarchy_relations WHERE child_id = 30 SELECT hr.child_id, h.rel, cp.level FROM cms3_hierarchy_relations hr, cms3_permissions cp, cms3_hierarchy h WHERE hr.rel_id = '30' AND h.id = hr.child_id AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND h.is_visible = '1' AND (cp.rel_id = h.id AND (cp.owner_id = '13') AND cp.level > 0) AND hr.level <= '1' ORDER BY hr.level, h.ord SELECT h.rel, h.type_id, h.lang_id, h.domain_id, h.tpl_id, h.obj_id, h.ord, h.alt_name, h.is_active, h.is_visible, h.is_deleted, h.updatetime, h.is_default, o.name FROM cms3_hierarchy h, cms3_objects o WHERE h.id = '53' AND o.id = h.obj_id SELECT rel_id FROM cms3_hierarchy_relations WHERE child_id = '53' ORDER BY id SELECT level FROM cms3_hierarchy_relations WHERE child_id = 53 SELECT hr.child_id, h.rel, cp.level FROM cms3_hierarchy_relations hr, cms3_permissions cp, cms3_hierarchy h WHERE hr.rel_id = '53' AND h.id = hr.child_id AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND h.is_visible = '1' AND (cp.rel_id = h.id AND (cp.owner_id = '13') AND cp.level > 0) AND hr.level <= '1' ORDER BY hr.level, h.ord SELECT id FROM cms3_object_types WHERE hierarchy_type_id = '30' LIMIT 1 SELECT level FROM cms3_hierarchy_relations WHERE child_id = 44 SELECT name, parent_id, is_locked, is_guidable, is_public, hierarchy_type_id, sortable, guid FROM cms3_object_types WHERE id = '53' SELECT ofg.id as groupId, cof.id, cof.name, cof.title, cof.is_locked, cof.is_inheritable, cof.is_visible, cof.field_type_id, cof.guide_id, cof.in_search, cof.in_filter, cof.tip, cof.is_required, cof.sortable, cof.is_system, cof.restriction_id FROM cms3_object_field_groups ofg, cms3_fields_controller cfc, cms3_object_fields cof WHERE ofg.type_id = '53' AND cfc.group_id = ofg.id AND cof.id = cfc.field_id ORDER BY ofg.ord ASC, cfc.ord ASC SELECT id, name, title, type_id, is_active, is_visible, is_locked, ord FROM cms3_object_field_groups WHERE type_id = '53' ORDER BY ord ASC SELECT id FROM cms3_object_types WHERE parent_id = '53' SELECT DISTINCT SQL_CALC_FOUND_ROWS h.id as id, h.rel as pid FROM cms3_hierarchy h, cms3_object_types t, cms3_permissions p, cms3_hierarchy_relations hr, cms3_objects o LEFT JOIN cms3_object_content oc_174_lj ON oc_174_lj.obj_id=o.id AND oc_174_lj.field_id = '174' WHERE o.type_id IN (53) AND t.id = o.type_id AND h.type_id IN (30) AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND (p.rel_id = h.id AND p.level & 1 AND p.owner_id IN(13)) AND h.id = hr.child_id AND (hr.level <= 1 AND hr.rel_id = '44') AND h.obj_id = o.id ORDER BY oc_174_lj.int_val DESC, h.ord ASC LIMIT 0, 2 Неперехваченное исключение

Неперехваченное исключение

Ошибка (databaseException): Expression #1 of ORDER BY clause is not in SELECT list, references column 'goldbook_db.oc_174_lj.int_val' which is not in SELECT list; this is incompatible with DISTINCT in query: SELECT DISTINCT SQL_CALC_FOUND_ROWS h.id as id, h.rel as pid FROM cms3_hierarchy h, cms3_object_types t, cms3_permissions p, cms3_hierarchy_relations hr, cms3_objects o LEFT JOIN cms3_object_content oc_174_lj ON oc_174_lj.obj_id=o.id AND oc_174_lj.field_id = '174' WHERE o.type_id IN (53) AND t.id = o.type_id AND h.type_id IN (30) AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND (p.rel_id = h.id AND p.level & 1 AND p.owner_id IN(13)) AND h.id = hr.child_id AND (hr.level <= 1 AND hr.rel_id = '44') AND h.obj_id = o.id ORDER BY oc_174_lj.int_val DESC, h.ord ASC LIMIT 0, 2

Показать отладочную информацию

SELECT DISTINCT SQL_CALC_FOUND_ROWS h.id as id, h.rel as pid FROM cms3_hierarchy h, cms3_object_types t, cms3_permissions p, cms3_hierarchy_relations hr, cms3_objects o LEFT JOIN cms3_object_content oc_174_lj ON oc_174_lj.obj_id=o.id AND oc_174_lj.field_id = '174' WHERE o.type_id IN (53) AND t.id = o.type_id AND h.type_id IN (30) AND h.lang_id = '1' AND h.is_deleted = '0' AND h.is_active = '1' AND (p.rel_id = h.id AND p.level & 1 AND p.owner_id IN(13)) AND h.id = hr.child_id AND (hr.level <= 1 AND hr.rel_id = '44') AND h.obj_id = o.id ORDER BY oc_174_lj.int_val DESC, h.ord ASC LIMIT 0, 2