> > I am writing Java UDFs using DB2 V8.2 (Fixpack 8) on Windows XP.
> >
[quoted text clipped - 34 lines]
> of classes in the sqllib/function/ directory (each in their own .class
> file) and they did work together quite nicely.
>> Java UDFs are just like any other Java program (except that the entry
>> point
[quoted text clipped - 13 lines]
> In other words, Foo is just a regular Java class and is *not* a UDF so no
> CREATE FUNCTION was ever executed for it.
What I meant is that from a Java/JVM perspective, there is absolutely
nothing special about Java UDFs that get called by the DB2 engine. A Java
UDF is like any other Java program. A Java program can invoke methods from
other classes, and so can a Java UDF. There is nothing in DB2 to prevent
you from calling methods of other classes.
> This is the situation I am trying to create but it isn't working. I'm
> wondering if it is possible. If it is possible, I don't understand why my
> UDF is not seeing the class when the UDF executes since I put the .class
> file in sqllib/function.
Something in your setup is amiss, I'd say. You should have a look at your
CLASSPATH that is available inside the UDF, i.e. what is the
java.class.path property set to? DB2 adds a few paths to the path set in
your enviroment.
The first result on google gave the V7 documentation, but you should also
find some relevant information there:
http://publib.boulder.ibm.com/infocenter/db2v7luw/index.jsp?topic=/com.ibm.db2v7
.doc/db2a0/db2a0162.htm

Signature
Knut Stolze
Information Integration
IBM Germany / University of Jena
Rhino - 22 Mar 2005 14:19 GMT
> >> Java UDFs are just like any other Java program (except that the entry
> >> point
[quoted text clipped - 19 lines]
> other classes, and so can a Java UDF. There is nothing in DB2 to prevent
> you from calling methods of other classes.
Excellent! That is exactly what I was hoping to hear. Now I know that it is
only my setup that has a problem, not that the whole thing is impossible
from the start.
> > This is the situation I am trying to create but it isn't working. I'm
> > wondering if it is possible. If it is possible, I don't understand why my
[quoted text clipped - 8 lines]
> The first result on google gave the V7 documentation, but you should also
> find some relevant information there:
http://publib.boulder.ibm.com/infocenter/db2v7luw/index.jsp?topic=/com.ibm.db2v7
.doc/db2a0/db2a0162.htm
Thank you! Now I should be able to sort out the problem.
Rhino