[Pgpool-general] stored procedures

Tatsuo Ishii ishii at sraoss.co.jp
Sat May 2 23:36:30 UTC 2009


> Tatsuo Ishii wrote:
> >> I assume that if I create a stored procedure that modifies the value in
> >> some table, pgpool won't propagate the change to all nodes if I access
> >> the procedure with a select:
> >>
> >> 	select foo_func('a', 'b');
> >>
> >> unless I have parallel queries enabled (which I don't want to do). Is
> >> this true? Will it work correctly if I structure the query as an update
> >> instead, like this
> >>
> >> 	update t set z=NULL where id in (select foo_func('a', 'b'));
> >>
> >> and 'id in ...' never matches anything so that t is never updated?
> > 
> > This should work but something like:
> > 
> > /*REPLICATE*/select foo_func('a', 'b');
> > 
> > would be more handy(the SQL comment can be anything you like).
> 
> Are you saying this works already or would be useful in the future?

I believe it works already.
--
Tatsuo Ishii
SRA OSS, Inc. Japan


More information about the Pgpool-general mailing list