If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Get All Permissions, Groups, roles for a user

Started by vamsivanka, 29 Jul 2016 08:30:20 AM

Previous topic - Next topic

vamsivanka

How to get all Permissions, groups, roles information for a user ?

Kiran P


Ravisha

Assuming that the content store DB is SQL Server...

Below are the queries to retrieve User Groups & User Roles information.

/* User Groups */

SELECT DISTINCT
P.CMID AS UserID
,P.NAME AS FirstLastName
,O.NAME

FROM [dbo].[CMOBJPROPS33] (nolock) P
JOIN [dbo].[CMREFORD1] (nolock) N ON P.CMID = N.REFCMID
JOIN (SELECT CMID, NAME FROM [dbo].[CMOBJNAMES] (nolock) WHERE MAPDLOCALEID in (24)) O ON N.CMID = O.CMID
JOIN [dbo].[CMOBJECTS] J (nolock) ON O.CMID = J.CMID
JOIN [dbo].[CMCLASSES] C (nolock) ON J.CLASSID = C.CLASSID
JOIN [dbo].[CMOBJPROPS1] P1 (nolock) ON P.CMID = P1.CMID

WHERE (J.CLASSID in (54) OR J.CLASSID is null)
AND P.NAME is not null

/* User Roles */

SELECT DISTINCT
P.CMID AS UserID
,P.NAME AS FirstLastName
,O.NAME

FROM [dbo].[CMOBJPROPS33] (nolock) P
JOIN [dbo].[CMREFORD1] (nolock) N ON P.CMID = N.REFCMID
JOIN (SELECT CMID, NAME FROM [dbo].[CMOBJNAMES] (nolock) WHERE MAPDLOCALEID in (24)) O ON N.CMID = O.CMID
JOIN [dbo].[CMOBJECTS] J (nolock) ON O.CMID = J.CMID
JOIN [dbo].[CMCLASSES] C (nolock) ON J.CLASSID = C.CLASSID
JOIN [dbo].[CMOBJPROPS1] P1 (nolock) ON P.CMID = P1.CMID

WHERE (J.CLASSID in (26) OR J.CLASSID is null)
AND P.NAME is not null