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

Home -> Community -> Usenet -> c.d.o.server -> Re: java stored procedures fast, but slow when called as SQL function

Re: java stored procedures fast, but slow when called as SQL function

From: <pete_at_mynix.org>
Date: 09 Apr 2003 15:51:51 +0200
Message-Id: <1049896369.88760.0@ersa.uk.clara.net>


wizofoz2k_at_yahoo.com.au (Nuno Souto) writes:

> pete_at_mynix.org wrote in message
> news:<1049837717.61400.0_at_ersa.uk.clara.net>...
>
>
> >
> > Yes: Java as a language is clearly faster than PL/SQL (you can measure
> > yourself),
>
>
> believe me: I've tried. Every signle time Java comes up
> considerably slower than PL/SQL...
>

?!? what have you done? I have measured myself and read comments form others: Java is consistently much faster in Java Stored Procedures than PL/SQL, as long as you don't interact too much with SQL. I.e. pure calculations are much faster in Java.

> > The only problem, as I think I have measured, is the binding between
> > the SQL engine and PL/SQL.
>
> You measured a problem in the binding between SQL and Java.
> There is NO problem with the PL/SQL and SQL binding.

Indeed, and what I said is that Java should be able (if Oracle wants) to reach the same level of binding. I cannot see a fundamental reason why this should not be possible.

> I think they didn't implement their own. They picked up a third party
> one and got it going. And they sort of "discourage" people running
> Java INSIDE the database engine nowadays. Much better to pick up
> an external JVM (with all that JIT stuff) and use jdbc to get at
> the data.
>
> Having said that, and before I get the usual barrage of URLs
> that "prove" Oracle still supports Java inside the db,
> let me stress it once again: Oracle ACTIVELY discourages anyone
> from using the in-built JVM in the database. Trust me, OK?
> ;)

Except that you cannot use external Java as an SQL function.

But aparently they discourage its use in-built. Thats new for me. Received on Wed Apr 09 2003 - 08:51:51 CDT

Original text of this message

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