Re: Removing triggers
From: Louis Davidson (dr_dontspamme_sql_at_hotmail.com)
Date: 03/05/04
- Next message: Joe Celko: "Re: Help with recursive queries... BIG problem."
- Previous message: Michas Konstantinos: "Re: NET SEND through xp_cmdshell"
- In reply to: Sam Moayedi: "Removing triggers"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 5 Mar 2004 10:12:34 -0600
I will have to assume you know what you are talking about, since what you
are suggesting sounds pretty strange.
To build a script, you can do something like:
--demo table
create table test
(
value int
)
go
--demo trigger
create trigger test$insert
on test
after insert
as
begin
declare @noop int
end
go
--this will generate a script
select 'drop trigger ' + name
from sysobjects
where name like 'test$%'
and objectproperty(id,'istrigger') = 1
-- ---------------------------------------------------------------------------- ----------- Louis Davidson (drsql@hotmail.com) Compass Technology Management Pro SQL Server 2000 Database Design http://www.apress.com/book/bookDisplay.html?bID=266 Note: Please reply to the newsgroups only unless you are interested in consulting services. All other replies will be ignored :) "Sam Moayedi" <anonymous@discussions.microsoft.com> wrote in message news:A6431B81-1E44-4E42-B8D9-FB7371B4A9D6@microsoft.com... > We have a Third part software which activates 3 trigger for each table, when I restore production server which does not have this application start getting error with these triggers. > Is there any easy way to remove all of these triggers on backup server? > They all start with specific key word (easy to identify)
- Next message: Joe Celko: "Re: Help with recursive queries... BIG problem."
- Previous message: Michas Konstantinos: "Re: NET SEND through xp_cmdshell"
- In reply to: Sam Moayedi: "Removing triggers"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|