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: Passing a record to a Java Stored Procedure

Re: Passing a record to a Java Stored Procedure

From: Chris McGrory <chris_at_worldsend.demon.co.uk>
Date: 2000/04/23
Message-ID: <956526429.15973.0.nnrp-14.c2de3e21@news.demon.co.uk>#1/1

Thanks for the suggestion - the main problem would be that the PL/SQL would have already fetched the record using a cursor - it seems wasteful to get it again....I suppose its block would be practically guaranteed to be in cache....

Chris McGrory (using another e-mail account today)

Thomas J. Kyte <tkyte_at_us.oracle.com> wrote in message news:8dpgjb$3f4$1_at_nnrp1.deja.com...
> In article <8dp1gg$krb$1_at_nnrp1.deja.com>,
> chris_mcgrory_at_my-deja.com wrote:
> > I wish to be able to pass a whole record eg table%
> > rowtype to a Java Stored Procedure (method) and
> > have the Java method calculate a CRC/Hash key to
> > be returned by the function. Environment is
> > Oracle 8.1.5 on Solaris.
> >
> > The problem is that at the PL/SQL - Java inteface
> > where I delcare the data types the PL/SQL wrapper
> > function won't allow a rowtype to be a parameter
> > [message is PLS-00999 "Functionality Not
> > implemented yet" or nearabouts]
> >
> > Ideally I would like to pass in a whole record
> > from any table - this would allow me to detect
> > record change at high speed inside the "history"
> > procedures of a Datawarehouse! Currently we
> > detect changes on a field by field basis big-wide
> > tables are too slow....
> >
> > The interfacing between PL/SQL and Java is all a
> > mystery to me - any information or suggestions
> > gladly accepted?....
> >
> > Sent via Deja.com http://www.deja.com/
> > Before you buy.
> >
>
> you cannot send plsql records types to another but another plsql
> routine.
>
> Even if you could -- you would still have to write a java stored
> procedure PER record type - probably not what you wanted to do (if we
> could pass a record to java from plsql, you would need a separate entry
> point for each unique record type you passed else how would it
> understand the datatypes, names of record fields, number of fields and
> so on...)
>
> How about if you just passed the tablename and ROWID to the java stored
> procedure and let it run the query:
>
> select * from T where rowid = :x
>
> into a result set and worked from there?
>
>
>
> --
> Thomas Kyte tkyte_at_us.oracle.com
> Oracle Service Industries
> http://osi.oracle.com/~tkyte/index.html
> --
> Opinions are mine and do not necessarily reflect those of Oracle Corp
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Sun Apr 23 2000 - 00:00:00 CDT

Original text of this message

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