Re: Schema Problems
- From: "Uri Dimant" <urid@xxxxxxxxxxx>
- Date: Thu, 3 Aug 2006 07:59:49 +0300
John
If the user is an owner of the object he/she will be able to delete them,
however , in SQL Server 2005 we have a new feature as DDL Triggers.
You can create a trigger on database level to DENY some users to delete/drop
whatever
CREATE TRIGGER trg_capture_drop_table ON DATABASE FOR DROP_TABLE
AS
-- PRINT event information For DEBUG
PRINT 'DROP TABLE Issued'
-- Can investigate data returned by EventData() and react accordingly.
RAISERROR('You cannot drop tables in this database.', 16, 1)
ROLLBACK
GO
DROP TABLE dbo.f
"John" <John@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:9B5D971B-416C-45B0-AF82-DFD548D9A04A@xxxxxxxxxxxxxxxx
SQL 2005
"Arnie Rowland" wrote:
What version of SQL Server are you using?
--
Arnie Rowland, Ph.D.
Westwood Consulting, Inc
Most good judgment comes from experience.
Most experience comes from bad judgment.
- Anonymous
"John" <John@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:E8E1DA25-757A-4C64-979A-038CBE8CCB7E@xxxxxxxxxxxxxxxx
I am trying to add a new developer to access our SQL 2005 box. I
created a
role called "developer" and added him to the role. In the properties
for
the
role, I added several tables for select permission and the create
procedure.
I would like him to be able to select from certain tables and insert
into
others (doesn't seem to be too hard to do). However, I would like to
allow
creation of sprocs and tables, buy DENY dropping any sprocs or tables.
it
seems like the only option is to grant the "alter" permission at the
schema
level (schema for all tables is dbo).
.
- Follow-Ups:
- Re: Schema Problems
- From: John
- Re: Schema Problems
- References:
- Re: Schema Problems
- From: Arnie Rowland
- Re: Schema Problems
- Prev by Date: Re: Orphaned user owns objects as dbo and cannot be dropped.
- Next by Date: Re: Owner granting permissions on his objetcs
- Previous by thread: Re: Schema Problems
- Next by thread: Re: Schema Problems
- Index(es):
Relevant Pages
|