Triggers

judesjudes Posts: 12
edited June 16, 2006 12:31PM in SQL Compare Previous Versions
Sorry for being daft, but how does one easily identify & move triggers between two databases being compared?

Comments

  • Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    Hello,

    No problem; SQL Compare really doesn't allow you to move triggers on their own, rather it compares and synchronizes the whole table schema including the columns, triggers, indexes, etc. It would synchronize all of these differences. You can turn it the other way and specifically ignore triggers from the comparison with a program setting. Otherwise SQL Compare requires you to move all differences between tables and can't just migrate the triggers by themselves.

    This could be done by writing some .NET code with SQL Toolkit as it is capable of getting the SQL script for all triggers in a database and allowing you to use this information to alter or create the triggers in a second database as needed.
This discussion has been closed.