May 28, 2009 at 8:29 am
hi guys, i have a table that i have set up for transactional replication.
this table gets populated with new data twice a day with a stored procedure containing a truncate table statement and an insert statement.
My question is when i run the transaction replication would the subscriber table also be trunncated or would it only keep inserting the data?
May 28, 2009 at 8:34 am
As per MSDN...
You cannot use TRUNCATE TABLE on tables that:
* Are referenced by a FOREIGN KEY constraint.
* Participate in an indexed view.
* Are published by using transactional replication or merge replication.
-Roy
May 28, 2009 at 8:51 am
ok thanks can i use delete?
May 28, 2009 at 8:55 am
Yes, you can use delete. And the delete will be propagated to the Subscriber.
PS: You can actually tell the replication agent not to propagate the delete command using some setting. I am not sure what the setting is since I have never used it. I read it somewhere here itself.
-Roy
May 28, 2009 at 11:51 am
thank you!
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply