db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rick Hillegas <Richard.Hille...@Sun.COM>
Subject Re: Aggregates
Date Wed, 21 Mar 2007 15:36:13 GMT
Hi Shelley,

There is an enhancement request logged for this feature: 
http://issues.apache.org/jira/browse/DERBY-672. No-one has picked up 
this enhancement request yet--you are welcome to! Most of the code 
needed for this feature is actually in the Derby codeline. I think the 
blocking issue is that the community must agree on syntax for declaring 
user defined aggregates.

Right now you can fake a user defined aggregate. An example of how to do 
this can be found in the scores demo package in java/demo/scores. For 
more details, please grep that subtree for "getMedianTestScore".

Hope this helps,
-Rick

Shelley L wrote:
> I need to use several aggregate functions, including most of the 
> built-in aggregates (count, min, max, avg, etc.) as well as some 
> custom aggregates (standard deviation and various percentiles).
>
> Is there any documentation or example on how to create custom 
> aggregate functions?  I have found one reference [1] which only 
> mentions that custom aggregates can be created, but contains no other 
> details.
>
> (Also, are there any plans to include standard deviation or 
> percentiles as built-in aggregates in derby?)
>
> [1] 
> http://db.apache.org/derby/docs/10.2/ref/rrefsqlj33923.html#rrefsqlj33923__sqlj92398

> <http://db.apache.org/derby/docs/10.2/ref/rrefsqlj33923.html#rrefsqlj33923__sqlj92398>


Mime
View raw message