Tuesday, March 20, 2012

Question on Querys

Ok in Replication for sql 2000,'

what happens when a query such as 'update tableA set a=1 where id=5' affects 1 row. What will happen when it does not affect any row.

Aaron

hi

1) with one row

in case of a merge replication => the updated Data replicated to the subscriber

in case of a transaction replication => the statement replicated and affects 1 rows on the subscriber again

2) with no row

in case of a merge replication => NOTHING

in case of a transaction replication => the statement replicated and affects 0 rows on the subscriber again

In Case of only one row, there is not big difference

in case of 100000 rows there is a big difference, because in case of merge replication, all of 100000 rows replicated step by step, in case of transaction replication, the statement will block the replication a long time, because the statement (not the result) will be replicate to the subscriber

bye

Thorsten Ueberschaer

No comments:

Post a Comment