1,642 questions

3,186 answers

1,714 comments

478 users

How to grant select permissions to dynamic GUID views

0 votes

I have a custom report that pulls revenue based on the revenue filter functionality in CRM. The revenue filters stored in CRM create views that contain the revenue split IDs that meet the filter requirements. The view is named VREVENUEFILTER[GUID]. The same is true for the UFN_REVENUEFILTER that gets created as well.

As new filters are created new views get created.

When I run my report through CRM I'm told that the Select permission is denied to the view.
I can manually grant permission to the BBAPPFXREPORTROLE to that view OR I can modify my report spec to include that view name in the Data Retrieval section and get the report to run.

Is there any way that I can assign these permissions in a way that as new views get created, or if I run the report on a new database it will have these select permissions?

asked Dec 21, 2017 by reportdeveloper80 (155 points)   4 7 15
edited Dec 21, 2017 by reportdeveloper80

1 Answer

0 votes
 
Best answer

I was able to find a single function that pulls the IDs based on the GUID of the revenue filter. This table value function doesn't change so I could add it to my Data Retrieval section and the report will now run without modifying permissions.

answered Dec 22, 2017 by reportdeveloper80 (155 points)   4 7 15
...