Bug in Oracle 9.2 JVM for stored procedures?

Hello,
     This may just be a change; we have some stored procedure code which uses reflection, which has worked fine under both Oracle 8 and Oracle 9. However, we're trying to get it working under 9.2, and we're running into the following problem.
     The code uses reflection to do database-column to object-field mapping. We have a private object constructor we'd like to call, and so we do a setAccessible() call on it, and this fails. We've done the suppressAccessChecks permission setup.
     This works fine under 8 and 9, but fails under 9.2.
     Clues?
     Thanks,
     --chris sterritt

We have a small source code example which shows this.
Also worth noting is that it works fine under Oracle 8.1.7.0.0, and fails under 9.2.0.1.0 (both running on Windows 2000) in case there are patches you recommend I get.
Thanks!
--chris sterritt                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

Similar Messages

  • How to check performance for Stored procedure or Package.

    Hi ,
    Can any one please tell me , how to check performance for Stored procedure or Function or Package
    Thanks&Regards,
    Sanjeev.

    user13483989 wrote:
    Hi ,
    Can any one please tell me , how to check performance for Stored procedure or Function or Package
    Thanks&Regards,
    Sanjeev.Oracle has provided set of Tools to monitor the Performance.
    Profilers being one of them; If you wish to understand more on PL/SQL Optimization, please read PL/SQL Optimization and Tuning.
    See example of DBMS_PROFILER.
    See example of PLSQL Hierarchial Profiler

  • ALDSP 3.0 -- schema owner for stored procedure or SQL Statement

    Using ALDSP, I have a need to create a physical service based on a stored procedure or a SQL statement. I am wondering what will happen when I move to another deployment environment where the schema owner changes. In our QA and Prod environments, we have a different schema owner for all tables in the application (the DBAs believe this prevents unwanted updates to a prod environment). DSP elegantly supports this for normal table- and view-based physical services by mapping schemas through the DSP console after deployment. Will I get the same type of mapping capability for stored procedures and SQL statements? I noticed that I can add a SQL-based function to a physical service...is there a way to pass in the physical table name from that data service to the procedure or SQL statement?
    Thanks,
    Jeff

    Schema name substitution should work for stored procedures just like it does for tables. If it doesn't - report a bug.
    You don't get any help for sql-statement based data services - dsp doesn't parse the sql provided. One thing you could do is use the default schema (following the user of your connection pool), and not specify the schema in your sql-statement.

  • Too many arguments for stored procedure call

    I have a stored procedure with 34 arguments, including the return value. I am trying to call it from java using JDBC thin drivers (jdk11, oracle815), but I get the "wrong number or types of arguments" error message. JDBC-OCI fails also. I saw a reference in this discussion group to there being a limit of 32 arguments for stored procedure calls from jdbc (posted 6/29/99). Is there such a limit? If so, is there a fix or workaround? If there is not a limit, how can I determine which argument is causing the problem?
    Many thanks.
    Mike
    java.sql.SQLException: ORA-06550: line 1, column 13:
    PLS-00306: wrong number or types of arguments in call to 'PUT_CHECK'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java)
    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java)
    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java)
    at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java)
    at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.jav
    a)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithBatch(OracleStatement
    .java)
    at oracle.jdbc.driver.OracleStatement.doExecute(OracleStatement.java)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStateme
    nt.java)
    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePrepar
    edStatement.java)
    at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStat
    ement.java)
    at metris.quickcheck.database.DS1.main(DS1.java:79)
    null

    I must confess I still don't understand your problem. By rows ...
    I have an sql that recodes a column and has 1450 rows. This doesn't work
    although when I use the same with less rows 40-60 it works.... do you mean rows in the table or elements in the CASE() statement ?
    From the 9i SQL Reference:
    " The maximum number of arguments in a CASE expression is 255, and each WHEN ... THEN pair counts as two arguments. To avoid exceeding the limit of 128 choices, you can nest CASE expressions. That is return_expr can itself be a CASE expression."
    According to the 10g docs the limit is the same there.
    Cheers, APC

  • Conversion of java Array to oracle SQL Array while calling Stored Procedure

    How java Array can be converted to oracle SQL array while calling Stored procedure with callable statement.
    i.e java Array ---> Sql Array in Oracle while setting the datatypes to callable statement arguments.

    Look at:
    http://forum.java.sun.com/thread.jsp?forum=48&thread=376735&tstart=0&trange=15
    Paul

  • Structure for Stored Procedure Call

    Hi All,
             Guys I am trying to call a stored procedure call using receiver jdbc adapter...
    This is the outgoing message:
    <b><?xml version="1.0" encoding="UTF-8" ?>
    - <ns0:SP_DB xmlns:ns0="urn:sce-com:xi:dev:mohammf">
    - <Test>
    - <PP_TEST_P action="EXECUTE">
      <table>PP_TEST_P</table>
      <RECTYPEIND type="CHAR">CC</RECTYPEIND>
      <JENUMBER type="CHAR">76724</JENUMBER>
      <COMPANY type="CHAR">BCEO</COMPANY>
      <CONSTANT1 type="CHAR">AB</CONSTANT1>
      <SYSTEMDATE type="CHAR">08/12/2007</SYSTEMDATE>
      <DR_CR_ID type="CHAR">0</DR_CR_ID>
      <AMOUNT type="CHAR">934928599475843</AMOUNT>
      <MONTH_NUMBER type="CHAR">000008</MONTH_NUMBER>
      <COST_CENTER type="CHAR">LosAngeles</COST_CENTER>
      <ORDERNO type="CHAR">694950375830</ORDERNO>
      <WBS type="CHAR">Southern California Edis</WBS>
      <ACCOUNTID type="CHAR">6949503758</ACCOUNTID>
      <BATCH_ID type="CHAR">3408102007</BATCH_ID>
      <ASSIGNMENT type="CHAR">Technology Solutio</ASSIGNMENT>
      <GL_JOURNAL_CATEGORY type="CHAR">GHTF</GL_JOURNAL_CATEGORY>
      <PROFIT_CENTER type="CHAR">3434694950</PROFIT_CENTER>
      <REFDOCNUMBER type="CHAR">00000000004304300056006056</REFDOCNUMBER>
      </PP_TEST_P>
    - <PP_TEST_P action="EXECUTE">
      <table>PP_TEST_P</table>
      <RECTYPEIND type="CHAR">XX</RECTYPEIND>
      <JENUMBER type="CHAR">76724</JENUMBER>
      <COMPANY type="CHAR">BCEO</COMPANY>
      <CONSTANT1 type="CHAR">AB</CONSTANT1>
      <SYSTEMDATE type="CHAR">08/12/2007</SYSTEMDATE>
      <DR_CR_ID type="CHAR">0</DR_CR_ID>
      <AMOUNT type="CHAR">934928599475843</AMOUNT>
      <MONTH_NUMBER type="CHAR">000008</MONTH_NUMBER>
      <COST_CENTER type="CHAR">LosAngeles</COST_CENTER>
      <ORDERNO type="CHAR">694950375830</ORDERNO>
      <WBS type="CHAR">Southern California Edis</WBS>
      <ACCOUNTID type="CHAR">6949503758</ACCOUNTID>
      <BATCH_ID type="CHAR">3408102007</BATCH_ID>
      <ASSIGNMENT type="CHAR">Technology Solutio</ASSIGNMENT>
      <GL_JOURNAL_CATEGORY type="CHAR">GHTF</GL_JOURNAL_CATEGORY>
      <PROFIT_CENTER type="CHAR">3434694950</PROFIT_CENTER>
      <REFDOCNUMBER type="CHAR">00000000004304300056006056</REFDOCNUMBER>
      </PP_TEST_P>
      </Test>
      </ns0:SP_DB></b>
    The error I am getting is: 
    <b><i>2007-08-20 09:44:05 Error Unable to execute statement for table or stored procedure. 'PP_TEST_P' (Structure 'Test') due to java.sql.SQLException: ERROR: Invalid XML document format for stored procedure: 'type="<SQL-type>"' attribute is missing for element 'table' (Setting a SQL-type (e.g. INTEGER, CHAR, DATE etc.) is mandatory !)
    2007-08-20 09:44:05 Error JDBC message processing failed; reason Error processing request in sax parser: Error when executing statement for table/stored proc. 'PP_TEST_P' (structure 'Test'): java.sql.SQLException: ERROR: Invalid XML document format for stored procedure: 'type="<SQL-type>"' attribute is missing for element 'table' (Setting a SQL-type (e.g. INTEGER, CHAR, DATE etc.) is mandatory !)
    2007-08-20 09:44:05 Error MP: Exception caught with cause com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'PP_TEST_P' (structure 'Test'): java.sql.SQLException: ERROR: Invalid XML document format for stored procedure: 'type="<SQL-type>"' attribute is missing for element 'table' (Setting a SQL-type (e.g. INTEGER, CHAR, DATE etc.) is mandatory !)
    2007-08-20 09:44:05 Error Exception caught by adapter framework: null
    2007-08-20 09:44:05 Error Delivery of the message to the application using connection JDBC_http://sap.com/xi/XI/System failed, due to: com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'PP_TEST_P' (structure 'Test'): java.sql.SQLException: ERROR: Invalid XML document format for stored procedure: 'type="<SQL-type>"' attribute is missing for element 'table' (Setting a SQL-type (e.g. INTEGER, CHAR, DATE etc.) is mandatory !).</i></b>
    Pls advice..
    XIer
    Message was edited by:
            XIer

    Hi,
    Check your DATA TYPE attributes with the attributes of the column names in the Database table.  There is a mismatch between the DT and Table in the database.
    <b>Cheers,
    *RAJ*</b>

  • How to use @prompt for stored procedure in universe

    Hi,
    I am using Bo XI R3.1 and universe was built on stored procedures and database is sql server 2005.
    I would like to show the list of values for prompts in report which they are based on parameters given for stored procedures in universe. Instead of typing the value for prompts the user should select some values for the prompt.
    I've tried in the universe putting the prompt syntax but didn't work could any one please let me know how this will be achived
    Thanks in advance,
    Eswar

    Hi Eswar,
    Please try the following steps mentioned below:
    1. Go to Insert -> click Tables and Import the table which needs to assign LOVu2019s into Universe panel.
    Objects which are created on tables may appear in inactive mode.
    2. Right click on the stored procedure -> Click on Edit stored procedures.
    3. Click on the Browse universe objects from Stored Procedure Editor. (Button avaial on the left)
    4. Select the object which you want to assign for the List of values.
    5. Enter the desired text which you want to display in the WebI reports in the Edit prompt Label.
    6. Export the Universe.
    Before doing the above steps:
    While creating for SP Univ, a parameter screen appears after selecting SP. In the "Value" field enter a dummy value and
    from the "Next Execution" drop down at the right select "Prompt me for a value".
    Regards,
    Rohit

  • Issue with Oracle.sql.NUMBER in Java Stored Procedure

    When we try to make a call to the Oracle.sql.NUMBER(String) inside a java stored procedure and pass values from '01' to '09', it throws java.lang.StringIndexOutOfBoundsException: String index out of range: 3
    We use Oracle 9.2.0.6 - JServer Release 9.2.0.6.0.
    It works fine for other values. Please find below the code used for simulating the issue outside the application. Thanks.
    create or replace and compile java source named testNumber as
    import oracle.sql.NUMBER;
    import java.sql.SQLException;
    public class TestNumber
           public static String convertNumber(String parm) {
                     NUMBER nTest;
                     try {
                             nTest = new NUMBER(parm);
                             return "TRUE";
                     }catch (SQLException sqle) {
                             return "FALSE";
    create or replace function test_number (p_str in varchar2) return varchar2 as
    language Java name 'TestNumber.convertNumber(java.lang.String) return
    java.lang.String';
    select test_number('05') from dual;  - Throws exception ORA-29532: Java call terminated by uncaught Java exception: java.lang.StringIndexOutOfBoundsException: String index out of range: 3
    select test_number('5') from dual; - Works fine
    select test_number('010') from dual; - Works fine

    Siva,
    I'm only guessing, but it could be an Oracle bug, in which case I suggest checking with Oracle Support.
    (You do have a support contract, don't you? ;-)
    Did you try compiling and running your java class "TestNumber" outside the database?
    Class "oracle.sql.NUMBER" should be in Oracle's JDBC driver, I believe.
    Good Luck,
    Avi.

  • How may one increase JVM/Java Stored Procedure Perfomance?

    Hi all,
    my question: How can one increase the performance of the Oracle JVM, especially of Java Stored Procedures?
    I ask this because I did some performance analysis (and was horrified :):
    I have a static Java method that'll need an average 15 ms to return - when executed locally.
    The same code, uploaded to an Oracle10g instance and published as Java Stored Procedure will take awful *925 ms*.
    I measured both times from within the method as shown below:
    public class JSProc {
    public static void doSomething() {
    long start = System.currentTimeMillis();
    // now comes the '15 ms'-code
    long time = System.currentTimeMillis() - start;
    That way, I'm not including any call spec overhead, network communication or whatever into the 925 ms. All in all the above procedure call will take about 1200 to 1500 ms until it returns to the client...
    The hardware: both client/server computers have the same hardware, both use the JDK provided with the latest Oracle10g release; single difference: client is Win2K, server is Linux.
    I would be immensely grateful for your suggestions concerning the possibilities to increase the JVM performance...
    Greetings,
    Sam

    As Avi suggested, subsequent calls of the procedure within the same session will reduce the execution time down to 40 ms in my testing environment.
    But that doesn't change anything for the 'first call' - when I start a new client program that opens a new connection, the Java Stored Proc will again need about a second to return.
    I wrote the procedure now in PL/SQL - it will return in less than 30 ms, subsequent calls will return in less than a ms. Guess what I'll use :)
    I played around with the JAVA* configuration params, but, as expected, that doesn't change anything in terms of performance. According to documentation, it will only affect the amount of classes I can load into the server.
    I just read that Oracle creates a new "little" JVM for every session, and I imagine that there's lot of method intercepting and things (the ominous AOP-code) to ensure transaction security.
    That's why I come to the conclusion that I won't use Java Stored Procedures for classical "connect, execute, disconnect" client-server applications. It's like full braking on the freeway :)

  • Pass parameter values for stored procedure in URL, possible?

    Hi, everyone, Our system is Apex4.0.2 in Linux CentOS 5 on Oracle 11GR2, here is the procedure:
    create or replace  procedure  test_public(Cust_id integer)
    is
    begin
    owa_util.mime_header( 'text/xml', FALSE );
    owa_util.mime_header( 'application/octet', FALSE );
    -- Close the HTTP Header
    owa_util.http_header_close;
    htp.p(DBMS_XMLGEN.getXML('SELECT * FROM demo_orders where customer_id='|| cust_ID));
    end;
    +/+
    the call to the stored procedure is SUCCESSFUL when Test_public has no parameters, like:
    http://myserver/apex/myschema.test_public (OK)
    the question is : I want to pass 3 parameters into my stored procedure(on production procedure), just don't know How?
    Any suggestions are greatly appreciated

    Thanks, Vee, definitely working, I do appreciate your help.
    I have to use Stored Procedure in Apex: my goal is to setup RESTful web service for IOS and Andriod alike, but APEX RESTful only supports SQL Report ( the RESTFUL check Box goes away with PL/SQL returning Query report, much to my surprise), I need expose some data and the same time I need insert/update some data when the client consumes our data, a PL/SQL based Report will do, but as I found out only simple SQL report has RESTful service, a Before REGION Process will do too, but web service connection WON'T fire that process (normal page display will fire the process) so I'm out of option.... Man I wish APEX REST is not so so basic....

  • SQL Developer Bug: NVL() function error when debug/run stored procedure

    Version:
    SQL Developer: 1.5.3 (build main-5783)
    Oracle DB connected: Oracle9i Enterprise Edition Release 9.2.0.6.0
    Stored procedure code like this:
    procedure search(V_STATUS_IN IN CHAR(1)) is
    begin
    declare
    V_STATUS CHAR(1) := NULL;
    begin
    V_STATUS := NVL(V_STATUS_IN, '%'); -- error line
    end;
    end;
    The stored procedure runs well (I mean no oracle exception) when called through Java code (and in TOAD). But when debug/run in SQL Developer, following error at the error line:
    $Oracle.EXCEPTION_ORA_6502:
    ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    --------------------------------------------------*/

    What parameter are you passing in? It is possible you are trying to cram a multibyte character into a singlebyte container. What are the nls settings for the database and for sqldeveloper?

  • Parse options for stored procedures in OMWB

    Hi all,
    I'll do apreciate it if somebody could explain me where i can find a detailed description for each stored procedures "parse options" in OMWB, like "generate maxilma pl/sql", "debug info", etc
    Thanks in advance..

    There is online help on this. On the Parse Options page press 'Help' then choose
    Stored Procedure: Parse Option Page
    Thank you for your time,
    Turloch
    Oracle Migration Workbench Team

  • Toplink support for stored procedure with 2 OUT  REF CURSOR ?

    Can Toplink StoredProcedureCall be used with Oracle PLSql procedure with 2 OUT parameters. Parameter type is Ref Cursor (Oracle PLSQL resulset)
    Regards

    In a TopLink StoredProcedureCall using an OUT CURSOR the cursor is assumed to map to the result set for the TopLink query.
    For example if you had a stored procedure READ_ALL_EMP that returned a out cursor of EMP rows, you could use that procedure in a TopLink mapped Employee class mapped to the EMP table and use the stored procedure in a ReadAllQuery for the Employee class.
    If the procedure does not return data that maps to objects, you can use a DataReadQuery to access the data. The out cursor would be returned as a Vector of DatabaseRows that contain the data from the cursor rows.
    If the procedures data is complex and does not map to objects, it may be better to access the procedure directly through JDBC.

  • How to fetch oracle process id from a stored procedure.

    Hi,
    I want to fetch the oracle process id from within a stored procedure.
    I know that the one way to do this is using the v$process view. But, a grant has to be given to the user on this table. Due to the strict policies at my workplace, I do not have the permission to do this, nor can i ask anyone to give the grant. But, i need the oracle pid very much.
    Is there an alternate way to get the oracle process id from within the stored procedure (without using the v$process view, like we have sys_context() to fetch session id without using v$session) ?
    Any help would be appreciated.
    Thanks,
    AP

    Hi,
    The point is i do not want to use v$process ( or v_$process) ,because i can not give the select grant to the user on this view. ( As i need to fetch it from a stored procedure, not from the SQL prompt).
    Rahul , your query is correct. It fetches the values ( though i needed oracle process id not unix pid ; i would get it through p.pid), but i need an alternate approach to this.
    Is there an alternate approach which would enable me to fetch the oracle process id ( without using any of the V$ - system views) ? Does Oracle has such a feature /approach ?
    -AP

  • Oracle error while using an stored procedure in forms

    Hi all,
    I used a stored procedure in a form,and it worked well.Recently i just update this procedure by desactivate some codes lines.The stored proc is well compile but when i try to use it in a form module, the following Oracle error occurs:
    ORA-04020     deadlock detected while trying to lock object name
    Cause:     While trying to lock a library object, a deadlock is detected.
    If some one have a solution to this problem, plz react to this topic
    TYAG.

    Hi all,
    I used a stored procedure in a form,and it worked well.Recently i just update this procedure by desactivate some codes lines.The stored proc is well compile but when i try to use it in a form module, the following Oracle error occurs:
    ORA-04020 deadlock detected while trying to lock object name
    Cause: While trying to lock a library object, a deadlock is detected.
    If some one have a solution to this problem, plz react to this topic
    TYAG.

Maybe you are looking for