SELECTDISTINCT(user_id)
FROMaacgb2v5_usergroups as ug1
INNERJOINaacgb2v5_usergroupsAS ug2 ON ug2.lft>=ug1.lft AND ug1.rgt>=ug2.rgt
INNERJOINaacgb2v5_user_usergroup_mapAS m ON ug2.id=m.group_id
WHERE ug1.id IN (8)

SELECTDISTINCT(user_id)
FROMaacgb2v5_usergroups as ug1
INNERJOINaacgb2v5_usergroupsAS ug2 ON ug2.lft>=ug1.lft AND ug1.rgt>=ug2.rgt
INNERJOINaacgb2v5_user_usergroup_mapAS m ON ug2.id=m.group_id
WHERE ug1.id IN (7)

SELECT user_id, category_id, role FROMaacgb2v5_kunena_user_categoriesWHERE role IN (1,2)

SHOWFULLCOLUMNSFROM `aacgb2v5_kunena_sessions`

SELECT*FROMaacgb2v5_kunena_categoriesORDERBY ordering, name

SELECTCOUNT(*) FROMaacgb2v5_kunena_topicsAS tt WHERE tt.hold IN (0) AND tt.category_id IN (2)

SELECT*FROMaacgb2v5_kunena_user_topicsWHERE user_id='0' AND topic_id IN (54,53,52,51,50,39,38,33,32,30,29,26,20,4,22,21,19,17,16,15)

SHOWFULLCOLUMNSFROM `aacgb2v5_kunena_user_topics`

SELECT*FROMaacgb2v5_kunena_keywords_mapAS m INNERJOINaacgb2v5_kunena_keywordsAS k ON m.keyword_id=k.id WHERE m.topic_id IN (54,53,52,51,50,39,38,33,32,30,29,26,20,4,22,21,19,17,16,15) AND m.user_id IN (0,0)