Hello
It is maybe a bug. I cannot use ORDER BY clause in two parameter aggregate.
create aggregate la(text, text) (SFUNC=listagg2_transfn,
STYPE=internal, FINALFUNC=listagg_finalfn);
postgres=# select la(town,',') from country;
la
---
Pavel Stehule pavel.steh...@gmail.com writes:
It is maybe a bug. I cannot use ORDER BY clause in two parameter aggregate.
I think you don't understand the syntax. Put the aggregate arguments
first, then the ORDER BY.
regards, tom lane
--
Sent via pgsql-hackers mailing
2009/12/25 Tom Lane t...@sss.pgh.pa.us:
Pavel Stehule pavel.steh...@gmail.com writes:
It is maybe a bug. I cannot use ORDER BY clause in two parameter aggregate.
I think you don't understand the syntax. Put the aggregate arguments
first, then the ORDER BY.
Sorry, I don't see it. Please,
2009/12/25 Pavel Stehule pavel.steh...@gmail.com:
2009/12/25 Tom Lane t...@sss.pgh.pa.us:
Pavel Stehule pavel.steh...@gmail.com writes:
It is maybe a bug. I cannot use ORDER BY clause in two parameter aggregate.
I think you don't understand the syntax. Put the aggregate arguments
first,
2009/12/25 Tom Lane t...@sss.pgh.pa.us:
Pavel Stehule pavel.steh...@gmail.com writes:
It is maybe a bug. I cannot use ORDER BY clause in two parameter aggregate.
I think you don't understand the syntax. Put the aggregate arguments
first, then the ORDER BY.
I was wrong. But it should be
Pavel Stehule pavel.steh...@gmail.com writes:
I was wrong. But it should be syntax error no?
SELECT foo(expr ORDER BY expr, .)
currently it quietly ignore arguments over ORDER BY clause.
No, because you could have more than one ORDER BY item.
regards, tom lane
2009/12/25 Tom Lane t...@sss.pgh.pa.us:
Pavel Stehule pavel.steh...@gmail.com writes:
I was wrong. But it should be syntax error no?
SELECT foo(expr ORDER BY expr, .)
currently it quietly ignore arguments over ORDER BY clause.
No, because you could have more than one ORDER BY item.
I
Pavel Stehule pavel.steh...@gmail.com writes:
2009/12/25 Tom Lane t...@sss.pgh.pa.us:
No, because you could have more than one ORDER BY item.
hmm - this isn't bullet-prof design :(
I notice that ORDER BY 'x' draws an error at the query level but not
within aggregates or window functions. I