Re: sequencial scans

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Vilson farias" <vilson(dot)farias(at)digitro(dot)com(dot)br>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: sequencial scans
Date: 2001-07-05 00:32:51
Message-ID: 1496.994293171@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Vilson farias" <vilson(dot)farias(at)digitro(dot)com(dot)br> writes:
> persona=# explain select * from teste_erro where cod = teste_proc('3138414411','19');
> NOTICE: QUERY PLAN:
> Seq Scan on teste_erro (cost=0.00..25.00 rows=10 width=4)
> EXPLAIN

You need to mark the function cachable, else the planner doesn't
believe it's a constant. See "iscachable" in the CREATE FUNCTION
reference page.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message CD Baby 2001-07-05 01:00:57 PostgreSQL ports post-installation gives core dump?
Previous Message simon lai 2001-07-04 23:42:32 Large table load (40 millon rows) - WAL hassles