Skip to main content

All Questions

Filter by
Sorted by
Tagged with
0 votes
2 answers
15k views

The EXECUTE permission was denied on the object 'SPROC', database 'DATABASE', schema 'dbo'

I have a few users that are unexpectedly receiving this error message today when they attempt to refresh a stored procedure via Excel: The EXECUTE permission was denied on the object 'SPROC', ...
gbeaven's user avatar
  • 213
1 vote
2 answers
638 views

Disabling Agent XPs causes sp_add_job (and sp_verify_job) to error with Msg 15281

Disabling Agent XPs is preventing sp_add_job from successfully running. When running through maintenance, our software is disabling Agent XPs. This needs to be fixed, but ALL of our other sites ...
DBADon's user avatar
  • 325
2 votes
1 answer
834 views

How I can impersonate a login with securityadmin server role

On MSSQL 2008R2 I have two instances on different servers, and I need sync up the password changes for all logins. I thing that i could create a store procedure where a user (impersonate) with ...
Diego Flores's user avatar
1 vote
1 answer
112 views

Forbid user to query internal SQL server information

I'm trying to forbid database user to get SQL server internal information. Script that creates DB user: CREATE USER [testuser] WITHOUT LOGIN WITH DEFAULT_SCHEMA=[dbo] DENY SELECT, INSERT, UPDATE, ...
Ghost Master's user avatar
3 votes
1 answer
1k views

DENY EXECUTE on one schema object hides other objects in same schema

I have five stored procedures in a schema [XTR], the users are all in one AD group [AD\Users] and have db_datareader and public assigned to them. On one of the stored procedures I don't want to give ...
nojetlag's user avatar
  • 2,907
-4 votes
1 answer
9k views

T-SQL to list all the user mappings with database roles/permissions for a User

I am looking for a t-sql script which can list the databases and and the respective roles/privileges mapped for a particular user. Using SQL Server 2008 R2. Regards Mohammed
Mohammed's user avatar