I have a series of stored procedures that select data from db. I have a role (cctc_reader) that has permissions to execute procedures. One of the procedures calls another stored procedure called recControl_system_option , which in turn queries Information_schema.columns .
The problem is that in this proc request
select column_name from information_schema.columns where table_name = 'recControl_manager'
does not return any records. cctc_reader has access permissions:
- every select proc
recControl_system_option
therefore theoretically this should work. I have no problem working under dbo.
If I give db_datareader to cctc_reader, the query will be fine, but I do not want to grant read permissions to all tables (hence why I used stored procs). I tried to grant permissions to access Information_schema in Master db, as suggested in some articles, but still cannot make it work.
Any suggestions?
source share