You need to sign in to do that
Don't have an account?
somasundaram s 7
get Inactive roles from SFDC using SOQL
hi guys,
I will try getting Inactive roles using soql .I unable to do this.If you know kindly share to me .
Thanks ,
Somu
I will try getting Inactive roles using soql .I unable to do this.If you know kindly share to me .
Thanks ,
Somu
Fields below is all the fields belong to UserRole object
ID
NAME
PARENTROLEID
ROLLUPDESCRIPTION
OPPORTUNITYACCESSFORACCOUNTOWNER
CASEACCESSFORACCOUNTOWNER
CONTACTACCESSFORACCOUNTOWNER
FORECASTUSERID
MAYFORECASTMANAGERSHARE
LASTMODIFIEDDATE
LASTMODIFIEDBYID
SYSTEMMODSTAMP
DEVELOPERNAME
PORTALACCOUNTID
PORTALTYPE
PORTALROLE
PORTALACCOUNTOWNERID
And There is no Active field at all.
【Inactive roles】 , do you mean the role is not used now?
The SOQL below that you can get all roles that is not used.
select id,name,DeveloperName from UserRole where id not in(select UserRoleId from user where UserRoleId != null )