On Wed, 26 May 2010, Altaf Malik wrote:
> I have a plpgsql function with raise notice statements in a loop. When I
> call this function from JDBC, it takes almost 5 minutes to execute. However,
> if I invoke it through pgAdminIII, it gets executed in just 12 seconds. The
> code of the function is given below:
>
> [plpgsql function issuing a ton of RAISE NOTICE statements]
>
> Any clue why JDBC is performing too slow?
>
I've committed a fix to CVS to fix this performance issue. We were
only tracking the head of the SQLWarning list so adding a new warning
was O(N). Now we track the tail of the list as well, so adding new
warnings is quick.
Kris Jurka