Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Triggers Execution


Triggers Execution

Author
Message
skgudi2009
skgudi2009
Grasshopper
Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)

Group: General Forum Members
Points: 16 Visits: 112
I HAVE HAVING 2 DATABASES 1 IS HAVING MORE THAN 25 TRIGGERS.I HAVE TO TAKE ALL 25 TRIGGERS AT A TIME AND EXECUTE IT IN ANOTHER DATABASE AT A TIME WITHOUT EXECUTING INDIVIDUALLY IS IT POSIBLE/
GilaMonster
GilaMonster
SSC-Forever
SSC-Forever (47K reputation)SSC-Forever (47K reputation)SSC-Forever (47K reputation)SSC-Forever (47K reputation)SSC-Forever (47K reputation)SSC-Forever (47K reputation)SSC-Forever (47K reputation)SSC-Forever (47K reputation)

Group: General Forum Members
Points: 47133 Visits: 44346
Your caps lock appears to be stuck, and I don't appreciate being shouted at...

Now, can you explain in a little more detail what you're trying to do here?


Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass


nigelrivett
nigelrivett
Old Hand
Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)

Group: General Forum Members
Points: 396 Visits: 211
Do you mean you want to copy the triggers to the other database?

Right click on the database and generate scripts.
Under scripting options, advanced you can select to script triggers.

You should be able to create a script of all the triggers which you can then run in the other database.

You can probably also do this via ssis.

If you want to exercise the triggers then you will have to look at them individually and see what updates to the underlying tables you need to make.


Cursors never.
DTS - only when needed and never to control.

skgudi2009
skgudi2009
Grasshopper
Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)

Group: General Forum Members
Points: 16 Visits: 112
I want to take only Triggers in Sql server 2008 R2 database to execute in another database.The Database having more than 25 triggers instead of excuting individually i want to take and execute 25 triggers at a time
nigelrivett
nigelrivett
Old Hand
Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)Old Hand (396 reputation)

Group: General Forum Members
Points: 396 Visits: 211
What do you mean by execute?
Do you want to add them to the tables in the database - if so see my previous post.
Do you want to cause the triggers to run by updating the underlying tables - if so see my previous post.
Something else
Maybe you want the triggers to be added to the tables in db1 and update the tables in db2.
In which case use the inserted and deleted tables to run the updates.


Cursors never.
DTS - only when needed and never to control.

Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search