Saturday, May 16, 2015

Parent and child group security information using Cognos content store sql query

eg: To find cognos parent and child security group relationship information using  sql query

Parent
Child
Country
State
State
City


SELECT rel.cmid parent_group_id, rel.cmid child_group_id, grp.CMID, cn.NAME AS child, cn1.NAME AS Parent  FROM
    cmreford1 rel
    Inner join cmobjects grp on   rel.refcmid = grp.cmid
    Left join cmobjnames cn on grp.cmid = cn.cmid
    Left join cmobjnames cn1 on rel.CMID = cn1.CMID where 
    grp.CMID in (948, 959) AND  cn.mapdlocaleid = 24