Re: Performance problems inside a stored procedure.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Matthew Lunnon wrote:

Ahh, sorry, I have been too aggressive with my cutting, I am running 8.2.6 and the function is below.

<snip>

$BODY$
 LANGUAGE 'sql' VOLATILE;
                 ^^^^^^^^^^
I suspect that it's because you're using VOLATILE (so no good optimizations is done); did you try STABLE? Could you show us the EXPLAIN ANALYZE of query and function?


--
  Euler Taveira de Oliveira
  http://www.timbira.com/

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

              http://archives.postgresql.org

[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux