469,950 Members | 1,958 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,950 developers. It's quick & easy.

Aggregate UDFs

The current issue of "Oracle Magazine" has an article on creating
custom aggregate functions, which naturally got me thinking about how
to do this in DB2.

I found some articles on creating custom aggregate functions in DB2,
written close to three years ago by Knut Stolze:

http://www-128.ibm.com/developerwork...309stolze.html

Mr. Stolze says in the first article that "[c]urrently, there is no
direct way to implement your own user-defined aggregate function." I'm
wondering if this still represents the state-of-the-art, or if there is
now (or will be in V9) a non-Java way to do it.

--Jeff

Jul 24 '06 #1
8 2934
jefftyzzer wrote:
The current issue of "Oracle Magazine" has an article on creating
custom aggregate functions, which naturally got me thinking about how
to do this in DB2.

I found some articles on creating custom aggregate functions in DB2,
written close to three years ago by Knut Stolze:

http://www-128.ibm.com/developerwork...309stolze.html

Mr. Stolze says in the first article that "[c]urrently, there is no
direct way to implement your own user-defined aggregate function." I'm
wondering if this still represents the state-of-the-art, or if there is
now (or will be in V9) a non-Java way to do it.
Yes, C :-)

--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

IOD Conference
http://www.ibm.com/software/data/ond...ness/conf2006/
Jul 25 '06 #2
Ouch! :-)

Although I think I now know the answer, allow me to rephrase for the
literal-minded: Is there now or is there planned native support for
user-defined aggregate functions?

--Jeff

Serge Rielau wrote:
jefftyzzer wrote:
The current issue of "Oracle Magazine" has an article on creating
custom aggregate functions, which naturally got me thinking about how
to do this in DB2.

I found some articles on creating custom aggregate functions in DB2,
written close to three years ago by Knut Stolze:

http://www-128.ibm.com/developerwork...309stolze.html

Mr. Stolze says in the first article that "[c]urrently, there is no
direct way to implement your own user-defined aggregate function." I'm
wondering if this still represents the state-of-the-art, or if there is
now (or will be in V9) a non-Java way to do it.
Yes, C :-)

--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

IOD Conference
http://www.ibm.com/software/data/ond...ness/conf2006/
Jul 25 '06 #3
jefftyzzer wrote:
Ouch! :-)

Although I think I now know the answer, allow me to rephrase for the
literal-minded: Is there now or is there planned native support for
user-defined aggregate functions?
There is no existing "native" support for user defined aggregates in DB2
including DB2 9. W.r.t. to plans you'll have to wait for either product
announcements or get yourself a non disclosure agreement.
The IBM DBMS which presently has user defined aggregates, and has had it
for years, is Informix IDS.
Are there any specific aggregates you're looking for?

Cheers
Serge
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

IOD Conference
http://www.ibm.com/software/data/ond...ness/conf2006/
Jul 25 '06 #4
jefftyzzer wrote:
Ouch! :-)

Although I think I now know the answer, allow me to rephrase for the
literal-minded: Is there now or is there planned native support for
user-defined aggregate functions?
Now (or V9): not that I'm aware of.
Planned: yes.

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
Jul 25 '06 #5
Serge Rielau wrote:
>Mr. Stolze says in the first article that "[c]urrently, there is no
direct way to implement your own user-defined aggregate function." I'm
wondering if this still represents the state-of-the-art, or if there is
now (or will be in V9) a non-Java way to do it.

Yes, C :-)
Actually, this aggregation stuff was originally developed in C. I ported it
to Java for the article to make it a bit simpler. Otherwise, I would have
had to explain shared memory etc.

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
Jul 25 '06 #6
Knut Stolze wrote:
Planned: yes.
Let me rephrase that: it is a known requirement and the DB2 developers are
thinking about implementing it.

--
Knut Stolze
DB2 Information Integration Development
IBM Germany
Jul 25 '06 #7
I'm not looking for any specific aggregate functions, I just thought
(think) it's a very cool capability (native or otherwise) and wanted to
look at it further. Thanks also for the reminder on Informix's
capabilities--I worked there back in the Finnochio/Dex/Stonebraker
days, and am heartened by IBM's continued support for--and development
on--the product.

--Jeff

Serge Rielau wrote:
jefftyzzer wrote:
Ouch! :-)

Although I think I now know the answer, allow me to rephrase for the
literal-minded: Is there now or is there planned native support for
user-defined aggregate functions?
There is no existing "native" support for user defined aggregates in DB2
including DB2 9. W.r.t. to plans you'll have to wait for either product
announcements or get yourself a non disclosure agreement.
The IBM DBMS which presently has user defined aggregates, and has had it
for years, is Informix IDS.
Are there any specific aggregates you're looking for?

Cheers
Serge
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

IOD Conference
http://www.ibm.com/software/data/ond...ness/conf2006/
Jul 25 '06 #8
jefftyzzer wrote:
I'm not looking for any specific aggregate functions, I just thought
(think) it's a very cool capability (native or otherwise) and wanted to
look at it further. Thanks also for the reminder on Informix's
capabilities--I worked there back in the Finnochio/Dex/Stonebraker
days, and am heartened by IBM's continued support for--and development
on--the product.
No contest on the usefulness of the feature. :-)
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

IOD Conference
http://www.ibm.com/software/data/ond...ness/conf2006/
Jul 25 '06 #9

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

6 posts views Thread by Larry Menard | last post: by
1 post views Thread by Najib Abi Fadel | last post: by
3 posts views Thread by Raghu | last post: by
reply views Thread by Helmut Tessarek | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.