Andrew Sullivan ajs at crankycanuck.ca
Wed Jul 4 08:35:15 PDT 2007
On Wed, Jul 04, 2007 at 12:03:11PM +0400, Dmitry Koterov wrote:
> log_cmddata="tbl_id=123 WHERE tbl_id=123"
> 
> The question is: why? Slaves do not need to perform this query at all, but
> it is propagated to them.

Slony can't know that, can it?

> I suppose that Slony generates log_cmddata comparing OLD and NEW
> field-by-field and then - insert only differences to log_cmddata. (If it is
> not true, and Slony performs a different algorythm, please detalize.) But,
> if there is no differences between OLD and NEW (as in above sample), no need
> to generate an event at all...

You might have to.  For instance, there could be a trigger STOREd on
the replica that needs to have this query show up there too.  One of
the problems with a general tool like Slony-I is that it has to do
work even when your specific case doesn't need it, because it can't
know everything (and getting it to check everything would impose
overhead that probably we don't want).

A

-- 
Andrew Sullivan  | ajs at crankycanuck.ca
In the future this spectacle of the middle classes shocking the avant-
garde will probably become the textbook definition of Postmodernism. 
                --Brad Holland


More information about the Slony1-general mailing list