Results 1 to 2 of 2
  1. #1
    Join Date
    Dec 2002

    Question Unanswered: How to complete Trigger on Table

    I need to create a trigger that fires when a record is inserted in a specific table.
    Having fired, the same record with a few altered fields wil be inserted to a table on a linked server.

    I need help to understand the requirements to make this work.

    What I have found out and configured so-far:
    I have linked the remote server to the server with the trigger.
    I have successfully added the trigger to the local Server

    What I need to know:
    How do I know the trigger is running ?
    Do I have to start it manually, or will it always be active ?
    How and where is it saved ?
    Once saved, can it be altered ?

    I apologize for the basic nature of my questions on triggers.


  2. #2
    Join Date
    Feb 2002
    Houston, TX
    To test your trigger, just insert three rows into your base table and when your statment has finished running look on your linked server to see that the rows have been added.

    Once the trigger has been "compiled" it is in effect and continuously running. The only exception to this is if you BCP data into the table, by default BCP does NOT fire triggers.

    A record of the trigger is placed in the sysobjects table and the text of the trigger is placed in the syscomments table.

    Yes, trigger can be modified or dropped.

    Books Online has an excelent write up on triggers.
    Paul Young
    (Knowledge is power! Get some!)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts