Skip site navigation (1) Skip section navigation (2)

Re: Memory usage on subselect

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Alexander M(dot) Pravking" <fduch(at)antar(dot)bryansk(dot)ru>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Memory usage on subselect
Date: 2004-05-23 16:28:18
Message-ID: (view raw or whole thread)
Lists: pgsql-sql
"Alexander M. Pravking" <fduch(at)antar(dot)bryansk(dot)ru> writes:
> I've got a memory usage problem when I try to do a subselect on the same
> table as the main select (PostgreSQL 7.3.4 on FreeBSD). Here's my query:
> ...
> The "services" table is indexed only on "id" column and has about a
> thousand tuples. sreq(integer, text, timestamptz) is a strict immutable
> function written in SQL.

IIRC, there were intraquery memory leaks associated with SQL-language
functions until fairly recently.  Can you try your problem case on 7.4?
Or see if you can rewrite the sreq function in plpgsql.

			regards, tom lane

In response to


pgsql-sql by date

Next:From: Alexander M. PravkingDate: 2004-05-23 18:32:49
Subject: Re: Memory usage on subselect
Previous:From: Alexander M. PravkingDate: 2004-05-22 17:54:19
Subject: Memory usage on subselect

Privacy Policy | About PostgreSQL
Copyright © 1996-2015 The PostgreSQL Global Development Group