October 18, 2016 at 10:31 am
We have some department users want to use excel to connect to our SQl server database, this way they can get most recent data.
For now we only want them to read the data, no write back to SQL database.
What is the best way of doing that, what permissions should we give for users in db?
October 18, 2016 at 11:00 am
The easiest way is probably just to add them to the db_datareader group in the database. Assuming you don't need any more granular permissions.
October 18, 2016 at 11:05 am
yes, sometimes I use stored procedure to return result.
So for those, I give user the public role, and grant execute to the stored procedure.
Is that OK?
Thanks,
October 18, 2016 at 11:06 am
ZZartin (10/18/2016)
The easiest way is probably just to add them to the db_datareader group in the database. Assuming you don't need any more granular permissions.
I'd create an AD group, put the users in that and then add the group to a suitable role ... to avoid individual user management in SQL Server.
If you haven't even tried to resolve your issue, please don't expect the hard-working volunteers here to waste their time providing links to answers which you could easily have found yourself.
October 18, 2016 at 11:07 am
sqlfriends (10/18/2016)
yes, sometimes I use stored procedure to return result.So for those, I give user the public role, and grant execute to the stored procedure.
Is that OK?
Thanks,
Not the best. Use a role and GRANT/DENY permissions to the role rather than the individual.
If you haven't even tried to resolve your issue, please don't expect the hard-working volunteers here to waste their time providing links to answers which you could easily have found yourself.
October 18, 2016 at 9:10 pm
Create a stored procedure to return what they want. Give them privs to run the stored procedure and have the stored procedure execute as owner. That way, you don't have to give them even read privs.
--Jeff Moden
Change is inevitable... Change for the better is not.
October 19, 2016 at 4:58 am
Jeff Moden (10/18/2016)
Create a stored procedure to return what they want. Give them privs to run the stored procedure and have the stored procedure execute as owner. That way, you don't have to give them even read privs.
Lowell
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply