Replicating Triggers

Miles writes "An associate of mine and I were attempting to include database triggers that we have developed in the replication of one of our databases. I had the idea of creating a trigger on the syscomments table so that whenever a trigger was updated on the master dB, all the other replicated databases would be updated with the newest version of the trigger. To our dismay, we were not allowed to create triggers on the system table. Is there any other way to do this? Thanks in advnace for your help!

At this time, in this version of SQL Server (7.0) you're not allowed to replicate triggers. Sorry, not the answer you were looking for.

Now...here's one way to do it. I'd suggest using a polling-application, or manually triggering the replication, and then using a remote call to xp_cmdshell to ISQL. Set the polling stored proc up to query something that contains the checksums from syscomments. Grab the actual trigger text from syscomments and build an ISQL query string, and then do a remote call via linked server to xp_cmdshell: