Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Calling Oracle stored procedures from Java app.

Re: Calling Oracle stored procedures from Java app.

From: Risto Lankinen <rlankine_at_us.oracle.com>
Date: 1998/01/24
Message-ID: <01bd28ac$5b5699d0$01010101@rlankine-hpc>#1/1

Hi!

Charles A. Christiansen, Jr. <charles_at_iconstructs.com> wrote in article <885416873.59703298_at_dejanews.com>...
> My question is, how do I call an
> Oracle stored procedure from my Java code? Is there a Java method that
> will handle this for me, or will it require some heavy duty coding to get
> working?

You may want to try the SQLJ precompiler in http://www.oracle.com . Click 'Download' (in left-hand panel)... 'Free Software' (in the text)... and see table 'SQLJ-Beta' for links to downloadable copies. You'll see choices for Windows and Unix, although the difference between them is in packing method of the archive, and the presence of line feeds in the text files only (Java code itself - in which SQLJ has been written - is pretty portable).

SQLJ is a precompiler which allows you to embed SQL calls into Java source. It is currently in beta, and it will translate the special hybrid language called SQLJ to pure Java which calls methods in JDBC and the SQLJ runtime. Even if you didn't want to use SQLJ for production it will be an excellent tool for understanding how to map SQL constructs to JDBC - just create the SQLJ source file, translate it to Java, and study the resulting source.

I am very sorry for sounding like a marketroid. In real life I'm one of the guys who wrote the precompiler, and I'm just very excited by the idea of having provided something useful to the Java community (indeed, I am replying to this message thru news:comp.lang.java).

Happy computing!

terv: Risto Lankinen Received on Sat Jan 24 1998 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US