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

Re: Stored procedure declared as VOLATILE => no good optimization is done

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Tatsuo Ishii <ishii(at)postgresql(dot)org>
Cc: mmoncure(at)gmail(dot)com, damon(at)huddler-inc(dot)com, pgsql-performance(at)postgresql(dot)org
Subject: Re: Stored procedure declared as VOLATILE => no good optimization is done
Date: 2010-10-16 02:31:34
Message-ID: 26735.1287196294@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-performance
Tatsuo Ishii <ishii(at)postgresql(dot)org> writes:
> So can I say "if a function is marked IMMUTABLE, then it should never
> modify database"? Is there any counter example?
> It seems if above is correct, I can say STABLE functions should never
> modify databases as well.

Both of those things are explicitly stated here:
http://developer.postgresql.org/pgdocs/postgres/xfunc-volatility.html

			regards, tom lane

In response to

Responses

pgsql-performance by date

Next:From: Craig RingerDate: 2010-10-16 02:59:33
Subject: Re: UUID performance as primary key
Previous:From: Navkirat SinghDate: 2010-10-16 01:58:04
Subject: UUID performance as primary key

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