Re: SPID question

From: Hilary Cotter (hilary.cotter_at_gmail.com)
Date: 02/21/05


Date: Mon, 21 Feb 2005 12:26:32 -0500

Transactional replication does not fire triggers. Are you perhaps thinking
of queued or immediate updating? Queued does use triggers which do use the
same SPID. Immediate Updating uses MSDTC to apply the transaction on the
publisher. I am not sure if the context would be the same spid, but triggers
are not involved.

-- 
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Brad Feaker" <BradFeaker@discussions.microsoft.com> wrote in message
news:C5766E15-A548-45BD-ADCC-35EAB6F46FC5@microsoft.com...
> When transactional replication fires an insert trigger on the subscriber
> server/database/table, does the trigger run under the same spid as the
> replication process that fires it?  Strange question, I know, but I have
to
> modify an insert trigger to fire only if the table has a row inserted from
> the OLTP application and to capture the inserted data from replication and
> process it at a later time.  I know this is a strange way to process, but
> this is what the client wants...Any suggestions appreciated.
>
> Regards,
>
> Brad Feaker
>
>
> -- 
> Brad Feaker
>


Relevant Pages

  • Re: DTS Data not being Replicated
    ... If you do a fast-load using the Transform Data task in DTS the triggers ... won't fire. ... In merge replication you can run sp_addtabletocontents to get ...
    (microsoft.public.sqlserver.replication)
  • Merge replication with summary tables that are affected by trigger
    ... As long as the triggers have not been created witht eh ... not for replication attribute, they'll fire. ... recommendation is to not have triggers firing on the ...
    (microsoft.public.sqlserver.replication)
  • Re: Immediately after initializing a merge subscription, why would the subscriber send back updates?
    ... one posibility is to mark the triggers as NOT FOR REPLICATION, ... cause them not to fire as a result of records changed during the ... Paul Ibison SQL Server MVP, ...
    (microsoft.public.sqlserver.replication)
  • constraints implemented in Triggers and replication
    ... What problems are you seeing from the triggers? ... don't want them to fire as a result of the replication ... you can specify NOT FOR REPLICATION on the ...
    (microsoft.public.sqlserver.replication)
  • Re: Replication, DTS, Triggers?
    ... If it goes the way I would hope, we would do incremental pulls of ... your saying it sounds like replication is the best starting point. ... > DTS is a great tool for pulling stuff in and making some (hopefully not ... > I'd avoid triggers if possible but that's just me. ...
    (microsoft.public.sqlserver.replication)