Re: select sum within transaction problem - Mailing list pgsql-sql

From Tom Lane
Subject Re: select sum within transaction problem
Date
Msg-id 28187.1189559353@sss.pgh.pa.us
Whole thread Raw
In response to select sum within transaction problem  ("Bart Degryse" <Bart.Degryse@indicator.be>)
List pgsql-sql
"Bart Degryse" <Bart.Degryse@indicator.be> writes:
> I have a function like below (simplified). Everything works the way I want =
> it to except for one thing.
> After the select statement sum_revenues is NULL instead of the real sum.
> Has this something to do with the earlier deletes and inserts not being =
> committed yet?

No.  I suspect the problem is hidden somewhere in the code you didn't
show us.  In particular you should check whether the insert/selects
are actually finding anything to insert ...
        regards, tom lane


pgsql-sql by date:

Previous
From: Paul Lambert
Date:
Subject: Re: Extracting hostname from URI column
Next
From: Paul Lambert
Date:
Subject: Re: Extracting hostname from URI column