December 12, 2006 at 5:05 am
hi !
how to meke the script of triggers only.
now wat im doing i have to take the tables n then triggers with it and then deleting the tables script. is there any simple way for just triggers only ?
Kindest Regards,
Atif Saeed Khan
December 12, 2006 at 6:57 am
In EM (Enterprise Manager)
Right click on the database
Select All Tasks / Generate SQL Script
Click Show All
Select All Tables (or select individual tables if required)
Click Formatting (tab)
Deselect the Generate CREATE / DROP options
Click Options (tab)
Select Script triggers
Select appropriate File Format and Create one file/individual files options
Click OK
Far away is close at hand in the images of elsewhere.
Anon.
December 12, 2006 at 10:09 am
here's another way, note that this does not order the triggers in dependancy order, it just lists them.
select parent_objects.name,
trigger_sysobjects.name,
syscomments.Text
from sysobjects trigger_sysobjects
inner join sysobjects parent_objects on parent_objects.id= trigger_sysobjects.parent_obj
inner join syscomments on trigger_sysobjects.id=syscomments.id
where trigger_sysobjects.xtype='TR'
Lowell
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply