Monday, March 26, 2012

How to run trigger against already-filled-table?

Hi all,
I am creating a trigger for table A. This trigger would insert some values
to table B. Problem is, the apss that uses this database is already running
for months by now and table A has filled with transaction values.
Question:
Is there any way that I could run the trigger (thus automatically insert
appropriate values to table B) based on the data that is _alread_ on table
B?
Looking forward to hearing from all of you!
TIA,
WilliantoI expect you can just run the trigger code in Query Analyzer. Just
paste in the code and then replace references to the INSERTED and
DELETED tables with the name of Table A.
David Portas
SQL Server MVP
--sql

No comments:

Post a Comment