I created some triggers in SQL Server 2012.
Now I create a Generate
scripts but I can not see triggers after publish
I created some triggers in SQL Server 2012.
Now I create a Generate
scripts but I can not see triggers after publish
If you used Management Studio to generate your scripts, then you likely didn't set the option to include triggers on script generation.
Look under Tools -> Options -> SQL Server Object Explorer -> Scripting -> Script Triggers
See http://msdn.microsoft.com/en-us/library/bb326600.aspx for reference and default values.
The triggers are not scripted by default - you have to include them specifically!
On the Generate and Publish Scripts
dialog, you need to click on the Advanced
button and in the dialog that pops up, you need to select Script triggers
and set it to TRUE
(it's FALSE
by default):