Re: [SQL] A query that doesn't work on 7.1

2001-03-08 Thread Tom Lane
Kyle <[EMAIL PROTECTED]> writes: >> You could probably gin up a usable avg(timestamp) using the avg(float8) >> routines, since a timestamp is really just a double under the hood. > When you say "gin up" are you talking about C, PL/XXX, or just casts? I was thinking of full-scale cheating: make a

Re: [SQL] A query that doesn't work on 7.1

2001-03-08 Thread Kyle
Tom Lane wrote: > Here's another twist though.  Is this a bug too or is this just beyond our reach? > psql:lead1.sql:64: ERROR:  Unable to select an aggregate function avg(date) It's just that we don't have any avg() function for date --- nor for timestamp, which is a little more surprising.   FY

Re: [SQL] A query that doesn't work on 7.1

2001-03-07 Thread Tom Lane
>> Here's a query that doesn't work on 7.1. Is this a bug or am I doing >> something wrong? > Hmm, I think you have found some subtle bugs in aggregate processing; > offhand it seems like both these queries should be legal. I'll see what > I can do about it. Not so subtle after all :-(. Curio

Re: [SQL] A query that doesn't work on 7.1

2001-03-07 Thread Tom Lane
Kyle <[EMAIL PROTECTED]> writes: > Here's a query that doesn't work on 7.1. Is this a bug or am I doing > something wrong? Hmm, I think you have found some subtle bugs in aggregate processing; offhand it seems like both these queries should be legal. I'll see what I can do about it.