É exatamente isso que eu tinha detectado!
Pelo que eu ententi, pretende-se resolver isso nas próximas versões do Post.

Obs: Aumentei consideravelmente o valor do parâmetro "work_mem" mas não houve 
melhoras.

Em Seg 08 Mai 2006 00:56, Otacilio Neto escreveu:
> Encontrei isto no manual:
>
> 36.7.1.2 RETURN NEXT
>
> Note
> The current implementation of RETURN NEXT for PL/pgSQL
> stores the entire result set before returning from the
> function, as discussed above. That means that if a
> PL/pgSQL function produces a very large result set,
> performance may be poor: data will be written to disk
> to avoid memory exhaustion, but the function itself
> will not return until the entire result set has been
> generated. A future version of PL/pgSQL may allow
> users to define set-returning functions that do not
> have this limitation. Currently, the point at which
> data begins being written to disk is controlled by the
> work_mem configuration variable. Administrators who
> have sufficient memory to store larger result sets in
> memory should consider increasing this parameter
_______________________________________________
Grupo de Usuários do PostgreSQL no Brasil
http://www.postgresql.org.br

Responder a