Tag: sql-server, tsql
What is the exact SQL to assign db_datareader and db_datawriter roles to a user in SQL Server?
Say the user name is MYUSER and the DB in question is MYDB.
Thanks!
cheeseballlumpy82 on Mar 05, 2013 Log in to Reply
use mydb go exec sp_addrolemember db_datareader, MYUSER go exec sp_addrolemember db_datawriter , MYUSER go
That’s ok if its on the wrong question here is the answer:
GRANT EXECUTE to MYUSER ; /* Grant to all store procs */ GO GRANT EXECUTE ON USP_LOADSOMEDATA TO MYUSER; /* Grant to as specific store procs */
cheeseballlumpy82 on Mar 05, 2013
cheeseballlumpy82 on Mar 05, 2013
That’s ok if its on the wrong question here is the answer: