Determining Role Access To Extender Objects


Patrick Roth - Click for blog homepageThis is a reposting of an article Patrick Roth originally wrote on my Developing for Dynamics GP blog.

An Extender case came up recently where the customer was having security issues with Extender forms.

To solve the issue, we needed to determine which Security Roles have access to particular Extender forms.

Note: This method uses the DYNAMICS.dbo.EXT00001 table which was added for version 10.0 Service Pack 4 and later.

We were able to resolve the issue by running a few SQL queries that were consolidated into one query as shown below.  I was able to, ahem, leverage David Musgrave’s SQL Security script here to get started.

SQL Query

SELECT ISNULL(A.SECURITYROLEID,'') AS SECURITYROLEID, ISNULL(M.SECURITYROLENAME,'') AS SECURITYROLENAME,
ISNULL(O.SECURITYTASKID,'') AS SECURITYTASKID, ISNULL(T.SECURITYTASKNAME,'') AS SECURITYTASKNAME ,ISNULL(T.SECURITYTASKDESC,'') AS SECURITYTASKDESC

from DYNAMICS.dbo.SY10700 O

left outer join DYNAMICS.dbo.EXT00001 EXT ON EXT.Extender_Resource_Number = O.SECURITYID
left outer JOIN DYNAMICS.dbo.SY09000 T ON T.SECURITYTASKID = O.SECURITYTASKID
left outer JOIN DYNAMICS.dbo.SY10600 A ON A.SECURITYTASKID = T.SECURITYTASKID
left outer JOIN DYNAMICS.dbo.SY09100 M ON M.SECURITYROLEID = A.SECURITYROLEID

where O.SECRESTYPE = 3107 and
O.DICTID = 3107 and
EXT.CMPANYID = -1 and --need to set the company
EXT.Extender_ID = 'BRACKET' --and need to set the extender name of the window

To check access, set the EXT.CMPANYID to the Company ID that you want to check access for.  Change the EXT.Extender_ID to the ID of the Extender object.

Result Set

SECURITYROLEID SECURITYROLENAME SECURITYTASKID SECURITYTASKNAME SECURITYTASKDESC
------------------------- --------------------------------------------------- ------------------------- ------------------------------------------------------------------------
AR CLERK* Account Receivables Clerk EXTENDER extender windows all extender windows

The results above show that the only role that can access to this Extender form named “BRACKET” is the AR CLERK* role in the selected company.  Any user in the POWERUSER role would also have access to the form as well.

Hope this helps out,

Patrick Roth
Microsoft Dynamics GP Developer Support

23-Nov-2010: Add note about compatible versions.

This article was originally posted on the Developing for Dynamics GP Blog and has been reposted on http://www.winthropdc.com/blog.

One thought on “Determining Role Access To Extender Objects

Please post feedback or comments

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.