Received: from sss.pgh.pa.us (sss.pgh.pa.us [209.114.132.154]) by mail.postgresql.org (8.11.1/8.11.1) with ESMTP id eARJAEt66995 for ; Mon, 27 Nov 2000 14:10:14 -0500 (EST) (envelope-from tgl@sss.pgh.pa.us) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.11.1/8.11.1) with ESMTP id eARJAOw11664; Mon, 27 Nov 2000 14:10:24 -0500 (EST) To: Anthony cc: pgsql-sql@postgresql.org Subject: Re: count( distinct x ) In-reply-to: <3A229EBB.F55BA11@a1.org.uk> References: <3A229EBB.F55BA11@a1.org.uk> Comments: In-reply-to Anthony message dated "Mon, 27 Nov 2000 17:49:47 +0000" Date: Mon, 27 Nov 2000 14:10:24 -0500 Message-ID: <11661.975352224@sss.pgh.pa.us> From: Tom Lane X-Archive-Number: 200011/247 X-Sequence-Number: 278 Anthony writes: > select count( distinct area ) from areapostcode where postcode like > 'BS1%' > the above statement fails with > ERROR: parser: parse error at or near "distinct" What Postgres version are you running? Support for count(distinct foo) was added in 7.0, IIRC. regards, tom lane