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

Home -> Community -> Mailing Lists -> Oracle-L -> Oracle Java stored procedure question

Oracle Java stored procedure question

From: <AdamDonahue_at_maximus.com>
Date: Thu, 11 Dec 2003 10:54:26 -0800
Message-ID: <F001.005D9911.20031211105426@fatcity.com>


Folks,

Anyone know if it's possible to pass a package record type as a parameter to a Java stored procedure?

e.g.,

create or replace package el_zip_pkg
is

        type file_rec_type is record (
                name    varchar2(255)
        ,       data    blob
        );

        type file_rec_list_type is table of file_rec_type;

        procedure create_zip_file( zip_file_name varchar2(255), files 
file_rec_list_type );
end el_zip_pkg;

create or replace package body el_zip_pkg is

        procedure create_zip_file( zip_file_name varchar2(255), files file_rec_list_type )

        is
        language java
        name 'com.maximus.hf.utils.Zipper.createZipFile( java.lang.String, 
oracle.sql.ARRAY )';
end el_zip_pkg;

This fails, complaining that a non-schema record type cannot be passed to a Java routine.

So, I'm using object types, but I can't embed these within the package -- I preferred to keep this structure packaged within its own namespace, rather than relying on additional types within the calling user's schema.

Any workarounds? Am I missing something obvious?

Adam

--

Please see the official ORACLE-L FAQ: http://www.orafaq.net
--

Author:
  INET: AdamDonahue_at_maximus.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Thu Dec 11 2003 - 12:54:26 CST

Original text of this message

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