Background
I'm using SQL Server 2008 R2's full text search to retrieve a number of documents, and wish to use the results of sys.dm_fts_parser
to highlight the matching terms.
Doing that ordinarily requires permissions an app user should not have. There is a solution proposed on MSDN as well as a deleted question/answer on StackOverflow (see why it was deleted).
Problem
I'm trying to implement the solution, but am unable to grant execute permission to the IIS App Pool user.
What I have tried
In SSMS under Security / Logins I created a user IIS APPPOOL\My App
. I grant that user db_datareader
and db_datawriter
for table access, and that works fine.
Again in SSMS:
- Under MyDB / Programmability / Stored Procedures I right-click on
dbo.usp_fts_parser
- Select Properties, Permissions.
- Click Search...
- Add
IIS APPPOOL\My App
- On the Explicit tab, Execute row I check Grant
- Click OK
Question
Why is this grant insufficient to execute dbo.usp_fts_parser
?
Notes
- I can execute it just fine from SSMS logged in as an administrator.
- If I temporarily grant the sysadmin Server Role to
IIS APPPOOL\My App
, the code is able to executedbo.usp_fts_parser