sql question after upgrade - Mailing list pgsql-sql

From James Cooper
Subject sql question after upgrade
Date
Msg-id 002f01c2dad6$c03bb470$c900a8c0@jax
Whole thread Raw
Responses Re: sql question after upgrade
Re: sql question after upgrade
List pgsql-sql

Hi just upgraded to 7.3.2 and imported my db schema with no probs!

Just wondering... why VOLATILE is being appended to my functions - can anyone ansewer me what this means? - should i be using joins instead, does this make a difference? If so an example of this would be much appreciated!!

CREATE FUNCTION public.get_people_total(int4) RETURNS int8 AS '
select count(person_id) as total from person where person_id IN
(
select cp.person_id from cluster_person cp, cluster c where cp.cluster_id = c.cluster_id and c.c_id = $1 group by cp.person_id
);
' LANGUAGE 'sql' VOLATILE;

 

cheers all

James

pgsql-sql by date:

Previous
From: Josh Berkus
Date:
Subject: Re: 7.3 "group by" issue
Next
From: Neil Conway
Date:
Subject: Re: sql question after upgrade