Re: syntax issue with custom aggregator - Mailing list pgsql-general

From Michael Fuhr
Subject Re: syntax issue with custom aggregator
Date
Msg-id 20050325195603.GA8604@winnie.fuhr.org
Whole thread Raw
In response to Re: syntax issue with custom aggregator  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
On Fri, Mar 25, 2005 at 02:39:11PM -0500, Tom Lane wrote:
> "Lucas F." <lucasf@vagabond-software.com> writes:
> > CREATE AGGREGATE "property"."pos_avg" ( BASETYPE = "int2",
> > SFUNC = "property"."ag_pos_avg_accum", STYPE = "_int4",
> > FINALFUNC = "property"."ag_pos_avg_final", INITCOND = "'{0,0}'");
>
> Too many quotes ... try INITCOND = '{0,0}'

Also, check the array subscripts in your functions.  By default,
PostgreSQL array subscripts start at 1, not 0.

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: syntax issue with custom aggregator
Next
From: Ragnar Hafstað
Date:
Subject: Re: sort array optimisation in pl/perl