Re: pl/pgsql question

From: "Josh Berkus" <josh(at)agliodbs(dot)com>
To: Tim Perdue <tim(at)perdue(dot)net>, Ludwig Lim <lud_nowhere_man(at)yahoo(dot)com>
Cc: PostgreSQL Mailing List <pgsql-sql(at)postgresql(dot)org>
Subject: Re: pl/pgsql question
Date: 2002-12-18 16:30:09
Message-ID: web-2290387@davinci.ethosmedia.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Tim,

> That loop apparently does not find any matching rows, which would
> have been inserted just before this row was, inside the same
> transaction.
>
> It was successfully finding those rows before, when the trigger was
> AFTER INSERT. If I manually select those rows after the query is
> committed, I am able to pull up the matching rows.

I think that triggers are probably not a good strategy for the kind of
calculation you're doing. I'd suggest instead a middleware module or a
"data push" function which would bundle all of the calculation logic
before calling any of the inserts.

-Josh

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Tim Perdue 2002-12-18 16:44:46 Re: pl/pgsql question
Previous Message Gary Stainburn 2002-12-18 16:25:11 references table(multiple columns go here)