Re: How to set Readonly for a user?

From: CurtM (cndmoyer@hotmail.com)
Date: 03/12/03


From: "CurtM" <cndmoyer@hotmail.com>
Date: Tue, 11 Mar 2003 16:13:52 -0800


Changing object ownership of stored procs can definitely
have an impact. The original owner can no longer execute
unless you grant permissions. But if these stored procs
are only run by one application or one user, that may not
be a big deal. Also: if you go this route, check inside
the stored proc to see if they're stored as "create
procedure as user1.nameofstoredproc..." You may have to
manually alter scripts that are like this - you'd have to
test in this case.
 
>-----Original Message-----
>Thanks for the tip.
>Regarding the sp_changeobjectowner, I don't know how this
would work and
>would it effect anyone else?
>
>John.
>
>"CurtM" <cndmoyer@hotmail.com> wrote in message
>news:076101c2e81e$62a26cf0$a001280a@phx.gbl...
>> 1. There is a db_datareader role that will allow that
user
>> to read everything in the database if that's acceptable.
>> 2. Can you do an sp_changeobjectowner on the stored
procs
>> and change them to the login's ownership? Then of
course
>> that login can execute those stored procs w/o granting
>> permissions.
>>
>> >-----Original Message-----
>> >Hi All,
>> >
>> >I'm new to this and would like some help understanding
>> how to set a user to
>> >have only read only access.
>> >I added an account and gave the account access to three
>> databases.
>> >Currently the only way they can get in, via a VB.NET
>> program, is to belong
>> >to the db_owner group. I would like to only allow
read-
>> only access but also
>> >need to allow for stored procs to EXEC. Do I have to
set
>> each individual
>> >attribute per database object?
>> >
>> >Thanks,
>> >John.
>> >
>> >
>> >.
>> >
>
>
>.
>



Relevant Pages

  • Dynamic SQL in Stored Proc
    ... I have a database setup so that NO users have READ, ... Dynamic SQL and they have stopped working. ... error message when executing one of the stored procs. ...
    (microsoft.public.sqlserver.security)
  • Re: Confused about proc vs. dynamic SQL vs LINQ
    ... where people create stored procs which *just* call normal CRUD ... for no reasons other than dogma. ... theoretical "change the database and the procs implementation, ... It depends on the database server, but I believe that using a cached ...
    (microsoft.public.dotnet.languages.csharp)
  • Question: How to pass ADS username from C# to trigger
    ... lot more auditing and the database seems like the place to do it. ... not want to modify all our stored procs to add username to it. ... We do have a centralized data access ...
    (microsoft.public.sqlserver.security)
  • Re: But a fool with a tool is still a fool
    ... You did say you were going to keep moving your logic into the database. ... You always need some business logic in the app, therefore also putting it in the database is to be avoided. ... You were advocating moving your business logic into stored procs. ... Jim Cooper jcooper@xxxxxxxxxxxxx ...
    (borland.public.delphi.non-technical)
  • Re: Help with SQL 2005 and Sourcesafe 6
    ... scripted stored procs in VSS, do you then have to, say, run an alter script ... would that update the stored proc in the database, ... If you check in a piece of VB codes does that also compile the VB ... Erland Sommarskog, SQL Server MVP, esquel@xxxxxxxxxxxxx ...
    (microsoft.public.sqlserver.tools)