ORA-23421 when calling dbms_defer_sys.schedule_purge

Hi all,
did anyone experience ORA-23421 when calling dbms_defer_sys.schedule_purge?
for settimg up an updatable materialized view replication between two Oracle 9.2 databases, I followed the steps detailed in "Oracle9i Replication Management API Reference" and when calling
DBMS_DEFER_SYS.SCHEDULE_PURGE (
next_date => SYSDATE,
interval => 'SYSDATE + 1/24',
delay_seconds => 0,
rollback_segment => '');
on the materialized view site, I get the error ORA-23421, telling me, that job number 48 is not a job in the job queue.
Do you have any idea, what's going wrong?
Thanks for your assistance
Siegfried Hartung

The answer could be found at http://www.orafaq.com/forum/t/66106/0/
From a previous run of the initialization scripts another user owned the job, that was adressed. The issue was resolved by changing the script in order to use the old userid (snapadmin instead of mvadmin).

Similar Messages

  • FRM-40735 / ORA-06508 when calling an attached package's procedure

    Hello all,
    I've a problem when calling a procedure in one of my attached libraries. the code is :
    when upper(trim(NOT_MSG_NAME)) = 'REN_MSG_REQ_REG_PERMENANT' then SERV.CLFRM_PBL_NRQP_F(:Parameter.NOTIFICATION_ID);
    and it gives me FRM-40735 stating that an ORA-06508 has occurred when calling the procedure.
    Important and funny thing is, when I add the path to the library , It works fine!
    When I attach it, removing the path, It goes wrong like I said..
    the location of the library is:D:\DevSuiteHome\cgenf61\ADMIN , the path is added in FORMS_PATH and all the other
    libraries attached to the form in the same path are working fine !
    I'm using forms builder 10.1.2.0.2, and the platform is windows and I've migrated from forms 9.0.4.0.19
    anybody having any ideas what the problem may be?

    Thank you Sarah
    In fact, somebody had modified the formsweb.cfg adding two working directory directives (It's a shared PC!). I recon none of them works though no configuration error is raised. I omitted both of them and the problem is gone .
    thank you again.

  • ORA-02074 when calling proc from VB

    Anyone have any idea why a stored procedure that sets a savepoint will fail with
    [Oracle][ODBC][Ora]ORA-02074: cannot ROLLBACK in a distributed transaction
    ORA-02074: cannot SET SAVEPOINT in a distributed transaction
    ORA-06512: at "PIPS_ADMIN.PKG_ACAS_COMMON", line 1098
    ORA-06512: at line 1
    when called from Visual Basic via an ADO connection through ODBC BUT
    will succeed when called from SQL*Plus or TOAD or other tool.
    Any ideas appreciated.
    Mike

    The change was only made to a local variable in a function that was called from the original function that got the parameters from the java client.
    I changed it from localtimestamp to systimestamp and it works fine.
    Do i have to make any settings about the time zone in the jdbc thin client ?

  • ORA-01804 when calling function from java client

    Hi All,
    we changed a PL/SQL-function that is called from a java client from using sysdate to localtimestamp. The function works fine in TOAD, but when called from the java client ist throws an ora-01804: failure to initialize timezone information.
    Any suggestions?
    Alexander

    The change was only made to a local variable in a function that was called from the original function that got the parameters from the java client.
    I changed it from localtimestamp to systimestamp and it works fine.
    Do i have to make any settings about the time zone in the jdbc thin client ?

  • ORA-06502 when calling from a procedure

    HI,
    I have a procedure(p1) inside a package that queries a table and send out the result based on the input paramater value. OUT variable is of same type as the table column(using %type), column size is varchar2(4000). This procedure is called from another procedure(p2) and sends out the result to Java Page to display the results at front-end.
    Problem is when application runs and p1 is called I get the following error message,
    ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    Length/size of the character string queried from table is _1747_ that is within the limit of 4000 chars. If I limit the output to just 500 using substr, I don't get any error but adding a single character startes throwing error. OUT variable in both p1 and p2 are declared as table.column%type and error comes from p1 only as confirmed by the error log.
    When I call p1 or p2 from a declare block, I don't get any error.
    This has really confused me and I am not able to find any reason for this difference in behaviour.
    Request to help me in understanding what could be the issue here.
    Oracle version used is Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit
    -Thanks in Advance.

    CREATE or replace PROCEDURE p1
    ( l_id IN VARCHAR2
    , l_str OUT VARCHAR2
    ) IS
      l_temp VARCHAR2(4000);
    BEGIN
      SELECT Response_Message INTO l_temp FROM t1 WHERE Response_ID = l_id;
      l_str := l_temp||'10 symbols';
    END;
    CREATE or replace PROCEDURE p2
    ( l_id IN VARCHAR2
    , l_str OUT VARCHAR2
    ) IS
    BEGIN
      p1(l_id, l_str);
    END;
    /no errors in procedures, but
    DECLARE
    resultstr VARCHAR2(1000);
    BEGIN
      p2(58, resultstr);
      DBMS_OUTPUT.PUT_LINE(resultstr);
    END;
    ERROR at line 1:
    ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    ORA-06512: at "P1", line 8
    ORA-06512: at "P2", line 6
    ORA-06512: at line 4Procedure is called with small variable.
    Try check all calls and all procedures for size and check if there are string concatenations.

  • ORA-06502 PL/SQL: numeric or value error ORA-06512 when calling a procedure

    Hi,
    I have been using ODP.net for a while now and have been calling lots of procedures without issue, however today I put together one to insert key, value parameters into a simple table and it is failing on me Intermittently with the ORA-06502... I have checked the code and I do not see any problems and am thoroughly frustrated... When I call the procedure directly it all works perfectly so the problem is not in the db!
    Please can you help? Code follows:
    Table defined as:
    CREATE TABLE REPORT_REQUEST_PARAMETERS
    (     REQUEST_ID NUMBER,
         PARAM_NAME VARCHAR2(50 BYTE),
         PARAM_VALUE VARCHAR2(255 BYTE)
    Stored procedure defined as:
    create or replace PROCEDURE SP_WRITE_REQUEST_PARAMS
    ( in_request_id number, in_param_name char, in_param_value char )
    AS
    BEGIN
    INSERT INTO REPORT_REQUEST_PARAMETERS ( REQUEST_ID, PARAM_NAME, PARAM_VALUE )
    VALUES
    ( in_request_id, in_param_name, in_param_value );
    END SP_WRITE_REQUEST_PARAMS;
    Finally the ODP.net code which calls this looks like:
    using (OracleConnection connection = new OracleConnection(...blah...))
    using (OracleCommand command = connection.CreateCommand())
    command.CommandType = CommandType.StoredProcedure;
    command.CommandText = "SP_WRITE_REQUEST_PARAMS";
    OracleParameter p1 = new OracleParameter("in_request_id", OracleDbType.Int32);
    OracleParameter p2 = new OracleParameter("in_param_name", OracleDbType.Char);
    OracleParameter p3 = new OracleParameter("in_param_value", OracleDbType.Char);
    p1.Direction = ParameterDirection.Input;
    p1.Value = requestId;
    p2.Direction = ParameterDirection.Input;
    p2.Size = paramName.Length;
    p2.Value = paramName;
    p3.Direction = ParameterDirection.Input;
    p3.Size = paramValue.Length;
    p3.Value = paramValue;
    command.Parameters.Add(p1);
    command.Parameters.Add(p2);
    command.Parameters.Add(p3);
    connection.Open();
    command.ExecuteNonQuery();
    connection.Close();
    }

    What version of database? If it's 9206 this is a known database problem, and should be resolved by patching the database to 9208. I don't have the bug number handy though.
    Simply because it succeeded in sqlplus doesnt mean it's not a database problem, as the problem was intermittent and succeeded from odp sometimes too.
    Thanks
    Greg

  • FRM-40735 with ORA-105100 when calling JavaBean in Forms6i deployed to Web

    We are encountering an ORA_JAVA error during runtime in a new simple form when trying to call an imported JavaBean in Forms 6i.
    It works when in the Forms6i Builder Run Form Client/Server mode on Linux/Motif.
    The specific error is: FRM-40735:WHEN-BUTTON-PRESSED trigger raised unhandled exception ORA-105100
    Our form incorporates the following simple example from Metalink Note:131964.1
    How to Create a Simple Java program with the ORA_JAVA Package of Forms?
    We have confirmed that we are downloading our custom JavaDev6i.jar file in the JInitiator console during runtime when deployed on the Forms Server using sockets.
    We have turned on Forms Runtime Diagnostics (FRD), which showed the following
    ORA_JAVA.LAST_ERROR: 121
    when attempting to execute the call to the JavaBean.
    I also ran strace on the forms processes:
    strace -o/tmp/f60srvm_trc.txt -afeT -p 21192 &
    strace -o/tmp/f60webmx_trc.txt -afeT -p 9172 &
    I found libjvm.so could not be found in the LD_LIBRARY_PATH,
    so I changed /d01/oracle/visappl/admin/adovars.env from:
    LD_LIBRARY_PATH=$ORACLE_HOME/network/jre11/lib/i686/native_threads:$ORACLE_HOME/network/jre11/lib/linux/native_threads:${LD_LIBRARY_PATH:=}
    to
    JDK131_HOME=/usr/java/jdk1.3.1_20
    export JDK131_HOME
    LD_LIBRARY_PATH=$JDK131_HOME/lib/i386:$JDK131_HOME/jre/lib/i386:$JDK131_HOME/jre/lib/i386/classic:$JDK131_HOME/jre/lib/i386/native_threads:${LD_LIBRARY_PATH:=}
    This solved that library problem, but it did not fix the original problem of not being able to run a JavaBean in a deployed Form.
    I've provided our environment below from txkMPcheck.sh, but please let me know what else you need to help us with this.
    Technology Validation Utility report for 11.5.9 Maintenance Pack (some info deleted to fit in forum 3.5K limit)
    Script : ./txkMPcheck.sh (115.20)
    Context : /d01/oracle/visappl/admin/VIS_hpbox.xml
    HTTP Server Node (hpbox):
    [PASS] Oracle JInitiator version from the Applications Context file is: 1.1.8.16
    [PASS] JDK version on HTTP server node is: 1.3.1_20
    [PASS] iAS version from the Applications Context file is: ias1022
    [PASS] iAS patchset version from the OUI inventory is: 1.3.19.0.0g
    [PASS] PERL is included in the PATH variable from the APPLSYS.env file.
    [PASS] DISPLAY variable from the Applications Context file is: :0.0
    Forms Server Node (hpbox):
    [PASS] Developer 6i version from f60gen executable is: 6.0.8.21.3
    [PASS] The 806 client library version from the f60gen executable is: 8.0.6.3.0
    [PASS] Checksum of file kpuex.o confirms back port 1227566 has been applied.
    [PASS] DISPLAY variable from the Applications Context file is: :0.0
    Administration Server Node (hpbox):
    [PASS] Database version from dbms_utility is: 9.2.0.3.0
    SUMMARY:
    [ALLPASS] All the technology checks on this node needed for the 11.5.9 Maintenance Pack
    have passed. You may now proceed with next steps in the Oracle
    Applications Release 11.5.9 Maintenance Pack Installation instructions.
    More env info...
    Oracle (Red Hat) Enterprise Linux Rel 4 Upd 6 (uname: 2.6.9-67.0.0.0.1.ELsmp #1 SMP)
    Forms6i Builder 6.0.8.21.3 (Production) (on Linux)
    Already posted this to Metalink forum, but no answer in 1 week.
    Thanks for your help!

    Looks like the CLASSPATH for the server is not set correctly. Does it include the directory where your JAR file resides?
    You say that the JavaDev6i.jar is downloaded the the JInitiator, which surprises me. It looks like you are trying to import/call Java from the server side, which means it is not necessary to load the JAR client side. You only have to include it in the client side JARs if you are using Pluggable Java Components (PJC) which run client side. You are using the Java Importer which creates a PL/SQL wrapper around a server side Java class.
    This might also explain why it does work in client/server mode. Then you might have a different CLASSPATH setup when starting Forms Runtime from within Forms Builder.

  • Encounter ORA-01002 when calling OCIStmtFetch2 to fetch blob data

    Oracle Version:Release 10.2.0.1.0
    Description:
    We use these two functions to fetch the content of blob field dynamically in batch mode:
    OCIDefineByPos(OCI_DYNAMIC_FETCH)
    OCIDefineDynamic(callbackfun->cbf_get_data)
    We allocate fixed memory to fetch data in order to using compact memory.
    If the size of blob to be fetched is larger than the allocated memory size, the fetch can not be done in one call, which need to be interrupted.
    Those records would remain in cache and can only be fetched until calling OCIStmtFetch2 next time.
    The callback function:cbf_get_data, achieves this by returning OCI_ROWCBK_DONE, which marks current fetch interrupted.
    It would not return OCI_CONTINUE, because OCI_CONTINUE can not interrupt current fetch procedure in time.
    We made a sample code test, and found this logic only works when fetching small rows (nearly 800 rows). Exceptions occurred when fetching more rows(>=1000 rows).
    For example, among these 2 cases,
    1.(OCIStmtFetch2(m_stmthp,m_errhp,(ub4)800,OCI_FETCH_NEXT,(sb4)OCI_FETCH_RELATIVE,OCI_DEFAULT)
    2.(OCIStmtFetch2(m_stmthp,m_errhp,(ub4)1000,OCI_FETCH_NEXT,(sb4)OCI_FETCH_RELATIVE,OCI_DEFAULT)
    only the 1st one work, but the 2nd.
    After function cbf_get_data returns OCI_ROWCBK_DONE, calling OCIStmtFetch2 did not enter into callback function cbf_get_data.
    And OCIErrorGet showed such error:
    ORA-01002: fetch out of sequence
    the total number of result set is about 100,000.
    We tried to set PREFETCH to a larger value in this way::
    OCIAttrSet(m_stmthp,OCI_HTYPE_STMT,(dvoid *)&rnum,0,OCI_ATTR_PREFETCH_ROWS,m_errhp);
    rtn=OCIAttrSet((dvoid *)m_stmthp, (ub4) OCI_HTYPE_STMT,(dvoid *)&preFetch, (ub4)sizeof(preFetch), OCI_ATTR_PREFETCH_MEMORY,m_errhp);
    but it did not help.
    Waiting for you guidance.
    Thanks in advance!
    -Andy
    Edited by: Andy Tong on 2010-10-22 上午12:29

    Here is our testing Code:
    #include "oci.h"
    #include<stdio.h>
    #include<stdlib.h>
    #include<string.h>
    #pragma comment(lib,"oci.lib")
    char buf1[5000];
    char buf2[5000];
    long datalen=5000;
    ub4 outpos=1;
    ub4 outpos2=2;
    int sum=0;
    int sum2=0;
    OCIError *m_errhp;
    OCIStmt *m_stmthp;
    char      LOBBuf[8006];
    long      LOBLen=8006;
    long     gindpp=0;
    ub2     grcpp=0;
    #define MAX_ROW_NUM 56338
    /* Fetch callback to specify buffers. */
    sb4 cbf_get_data(     dvoid*          ctxp,
                             OCIDefine*     dfnhp,
                             ub4               iter,
                             dvoid**          bufpp,
                             ub4**          alenpp,
                             ub1*          piecep,
                             dvoid**          indpp,
                             ub2**          rcpp)
         if(iter==0)
              sum=0;
         else if(iter>=858) //857 exception
              //LOBBuf,LOBLen
              //     sum+=LOBLen;
              //     if(sum>1057552-100*1024)
              sum=0;
              bufpp=(dvoid)0;
              alenpp=(ub4)0;
              *piecep = (ub1)OCI_ONE_PIECE;
              indpp = (dvoid ) 0;
              rcpp     = (ub2 ) 0;
              return(OCI_ROWCBK_DONE);     
         LOBLen=8006;
         bufpp=(dvoid)LOBBuf;
         alenpp=(ub4)&LOBLen;
         *piecep = (ub1)OCI_ONE_PIECE;
         indpp = (dvoid )&gindpp;
         rcpp     = (ub2 )&grcpp;
         return(OCI_CONTINUE);     
    BOOL CTest_ociApp::InitInstance()
         OCIEnv *          m_envhp;
         OCIServer *          m_srvhp;
         OCISvcCtx *          m_svchp;
         sword               rtn;
         char               sqlState[256];
         int               nativeErr;
         char               errTxt[256];
         unsigned long          bufLen=256;
         OCIDefine hDefine =  (OCIDefine ) 0;
         OCIDefine hDefine1 = (OCIDefine ) 0;
         OCIDefine hDefine2 = (OCIDefine ) 0;
         OCIDefine hDefine3 = (OCIDefine ) 0;
         OCIDefine hDefine4 = (OCIDefine ) 0;
         int i;
         OCILobLocator** lob_array;
         char username[255];
         char password[30];
         char dbname[30];
         char szSqlStr[255];
         ub4 preFetch= 10*1024*16;
         strcpy(username,"dlg25w");
         strcpy(password,"sa");
         strcpy(dbname,"WIN10G");
         OCIEnvCreate(&m_envhp, OCI_DEFAULT | OCI_OBJECT, 0, 0, 0, 0, 0, 0);
         OCIHandleAlloc( (dvoid *)m_envhp, (dvoid **)&m_errhp,OCI_HTYPE_ERROR,(size_t) 0, (dvoid **) 0);
         OCIHandleAlloc( (dvoid *)m_envhp, (dvoid **)&m_srvhp,OCI_HTYPE_SERVER,(size_t) 0, (dvoid **) 0);
         OCIHandleAlloc( (dvoid *)m_envhp, (dvoid **)&m_svchp,OCI_HTYPE_SVCCTX,(size_t) 0, (dvoid **) 0);
         OCIHandleAlloc( (dvoid *)m_envhp, (dvoid **)&m_stmthp,OCI_HTYPE_STMT,(size_t) 0, (dvoid **)0);
         OCIServerAttach(m_srvhp, m_errhp,(text *)dbname, strlen(dbname),(ub4) OCI_DEFAULT);
         OCILogon(m_envhp,m_errhp,&m_svchp,(text *)username,strlen(username),(text *)password,strlen(password),(text *)dbname,strlen(dbname));
         ub4     rnum=0;
         unsigned int len=0;
         //rtn=OCIAttrGet(m_envhp,OCI_HTYPE_ENV,(dvoid *)&rnum,&len,OCI_ATTR_CACHE_MAX_SIZE,m_errhp);
         OCIErrorGet((dvoid *) m_errhp,(ub4)1,(OraText *)sqlState,&nativeErr,(unsigned char*)errTxt,bufLen,(ub4) OCI_HTYPE_ERROR);
         len=4;
         rnum=83886080;
         rtn=OCIAttrSet(m_envhp,OCI_HTYPE_ENV,(dvoid *)&rnum,len,OCI_ATTR_CACHE_OPT_SIZE,m_errhp);
         rtn=OCIAttrGet(m_envhp,OCI_HTYPE_ENV,(dvoid *)&rnum,&len,OCI_ATTR_CACHE_OPT_SIZE,m_errhp);
         OCIErrorGet((dvoid *) m_errhp,(ub4)1,(OraText *)sqlState,&nativeErr,(unsigned char*)errTxt,bufLen,(ub4) OCI_HTYPE_ERROR);
         rnum=2000;
         sprintf( szSqlStr,"%s", "SELECT DATA FROM MF4");
         OCIStmtPrepare(m_stmthp, m_errhp, (text*)szSqlStr, (ub4)strlen(szSqlStr),(ub4) OCI_NTV_SYNTAX, (ub4)OCI_DEFAULT);
    OCIAttrSet(m_stmthp,OCI_HTYPE_STMT,(dvoid *)&rnum,0,OCI_ATTR_PREFETCH_ROWS,m_errhp);
         /* initialize array of locators */
         OCIDefineByPos(m_stmthp, &hDefine2, m_errhp, (ub4)1,(dvoid *)0,(sb4)8006,SQLT_BIN,(dvoid *)0, (ub2 *)0, (ub2 *)0,(ub4) OCI_DYNAMIC_FETCH);//OCI_DYNAMIC_FETCH
         OCIDefineDynamic(hDefine2, m_errhp, (dvoid *)&outpos,(OCICallbackDefine)cbf_get_data);
         OCIStmtExecute(m_svchp, m_stmthp, m_errhp,(ub4)0, (ub4) 0,(const OCISnapshot*) 0,
              (OCISnapshot*)0,(ub4)OCI_DEFAULT);//OCI_STMT_SCROLLABLE_READONLY
         rtn=OCIAttrSet((dvoid *)m_stmthp, (ub4) OCI_HTYPE_STMT,(dvoid *)&preFetch, (ub4)sizeof(preFetch), OCI_ATTR_PREFETCH_MEMORY,m_errhp);
         while(1)
              rtn=OCIStmtFetch2(m_stmthp,m_errhp,(ub4)1000,OCI_FETCH_NEXT,(sb4)OCI_FETCH_RELATIVE,OCI_DEFAULT);
              OCIErrorGet((dvoid *) m_errhp,(ub4)1,(OraText *)sqlState,&nativeErr,(unsigned char*)errTxt,bufLen,(ub4) OCI_HTYPE_ERROR);
              if(rtn==OCI_NO_DATA)
                   break;
              else
         t0=GetTickCount()-t0;
         t0=0;
         OCIAttrGet((CONST void *)m_stmthp,OCI_HTYPE_STMT,(void *)&rows_fetched,(ub4 *)sizeof(rows_fetched),OCI_ATTR_ROW_COUNT ,m_errhp);
         printf("\n Total number of records:%d",rows_fetched);
         OCILogoff( m_svchp, m_errhp );
         OCIServerDetach( m_srvhp, m_errhp, OCI_DEFAULT );
         OCIHandleFree((dvoid *) m_stmthp, OCI_HTYPE_STMT);
         OCIHandleFree((dvoid *) m_svchp, OCI_HTYPE_SVCCTX);
         OCIHandleFree((dvoid *) m_srvhp, OCI_HTYPE_SERVER);
         OCIHandleFree((dvoid *) m_errhp, OCI_HTYPE_ERROR);
         getchar();
         return FALSE;
    }

  • ORA-28509 when calling PL/SQL mq message throught Java Application

    I have a PL/SQL procedure called "prc_send_mq_message" witch works perfectly when I invoke throught database users where it is compiled.
    But when this same procedure is invoked by Java Application witch connects with the same user, the error: "ORA-28509: was not possible stablish connectinon with Non_Database Oracle" happens.
    Can anyone help me ?
    See pl/sqlblock bellow:
    Create or replace procedure prc_send_mq_message Is
    pi_db_link_name Varchar2(100) := 'siibdg4mq';
    pi_queue_name Varchar2(100) := 'QL.REQ.SIIB.FBS.01';
    vObjDesc PGM.MQOD;
    vHandleObj PGM.MQOH;
    vMsgDesc PGM.MQMD;
    vPutOpt PGM.MQPMO;
    --options PGM.MQPMO;
    vPutBuffer Raw(32767);
    Begin
    -- Opening the queue:
    vObjDesc.DBLINKNAME := pi_db_link_name;
    vObjDesc.OBJECTNAME := pi_queue_name;
    pgm.mqopen( vObjDesc, PGM_SUP.MQOO_OUTPUT, vHandleObj ); --> ORA-28509: was not possible stablish connectinon with Non_Database Oracle
    End;
    /

    Hi,
    This is the Oracle MessageQ forum, not the WebLogic Server, Oracle Database, or Oracle JMS forum. You will likely have better success in getting your question answered by using one of the Database related forums.
    Regards,
    Todd Little
    Oracle Tuxedo Chief Architect

  • ORA-904 when calling a sys package from a private one (on 9.2.0.5.0)

    Hi,
    I explain:
    SELECT DBMS_PIPE.UNIQUE_SESSION_NAME
    FROM dual;
    works!!!
    CREATE OR REPLACE FUNCTION GET_NAME RETURN VARCHAR2 IS
    vc_name VARCHAR2(1000);
    BEGIN
    SELECT DBMS_PIPE.UNIQUE_SESSION_NAME
    INTO vc_name
    FROM dual;
    RETURN vc_name;
    END GET_NAME;
    works (no error at compile time)
    BUT:
    SELECT GET_NAME FROM DUAL;
    Get a ORA-00904 error:
    ORA-00904: : identificateur non valide
    ORA-06512: at "DBASYS.GET_NAME", line 4
    This mean that DBMS_PIPE.UNIQUE_SESSION_NAME
    is unknown.
    But I used it from the same session just before.
    What is the problem ?
    This example is simple, I HAVE TO use a function, in my true function, I do things before and after the call.
    Thanks.
    Christian COMMARMOND (France)

    Hi Kamal,
    Thank you for taking care of my problem...
    About:
    CREATE OR REPLACE FUNCTION GET_NAME RETURN VARCHAR2 IS
    vc_name VARCHAR2(1000);
    BEGIN
    vc_name := DBMS_PIPE.UNIQUE_SESSION_NAME;
    RETURN(vc_name);
    END GET_NAME;
    I can not even compile it, I get PLS-00021 DBMS_PIPE UNKNOWN (the message is in french so my translation could differ of the real oracle message but code is OK)
    I think that this is the problem of GRANTed objects. It seems that even if my account is DBA, my procs does not inherit of the 'public' grants and that the real owner of the object should GRANT to me the EXECUTE.
    If this is the problem, I do not have the SYS password to do the GRANT.
    Do you think there could be a work around?
    Thanks again,
    Christian COMMARMOND

  • ORA-28868 error when calling Web service over HTTPS from PL/SQL utl_http

    I am getting error message ORA-28868 error when calling Web service over HTTPS from PL/SQL utl_http PL/SQL package,
    when browsed through some of the messages they point to setting Oracle Wallet Manager.
    I am trying to connect
    Any idea on how to resolve this issue ?
    your input is appreciated.
    Thanks
    Ravi

    Duplicate post ... please ignore.

  • ORA-03115 error when calling a Stored Procedure

    Hi All,
    I'm in the process of porting a Pro/C app from NT to Linux. I've installed 8.1.5 on our Linux box and patched it up to 8.1.5.02.
    It all kind of works ok, except that I'm sometimes getting ORA-03115 errors when the app calls a stored procedure. The call in question looks like this:
    EXEC SQL BEGIN DECLARE SECTION;
    VARCHAR resprows[50][3998];
    int numret = 0;
    int numrows= 50;
    int done= 0;
    unsigned long resp_id = 0;
    EXEC SQL END DECLARE SECTION;
    EXEC SQL AT DB_NAME EXECUTE
    BEGIN pkg_something.getdata(
    :resp_id, /* IN */
    :numrows, /* IN */
    :done, /* OUT */
    :resprows, /* OUT */
    :numret /* OUT */
    END;
    END-EXEC;
    The stored procedure basically uses the resp_id value to select rows from a table;
    in each row there is a VARCHAR2(4000) column which it copies into the hostarray resprows.
    There may be anything from 1 to numrows returned from the SP.
    Initially, the resprows rows were defined to be size [4000]. Unfortunately, this caused ORA-02005 errors - I then changed the size to [3998], which seemed to fix the 02005's (although I'm unclear as to the reasons why).
    Now I'm getting the 03115 errors when calling the SP. The oracle manual is not very helpful on what this error means.
    This all works chipper on NT.
    Any ideas?
    Thanks in advance,
    Nigel.
    PS: The database the app is talking to is still hosted on NT.
    null

    Histon FTM wrote:
    ORA-04063: package body "LAZARUS.LAZARUS" has errors Above, obviously conflicts with the statement that follows:
    >
    The procedure and package have both compiled without errors and the statement on its own works fine in SQL*Plus.I suggest you take a look in the USER_ERRORS view to see, what the errors are.
    And just checking:
    You have schema called LAZARUS, which holds a package named LAZARUS, which holds a procedure called POPULATEGRIDPOSITIONS?
    Edited by: Toon Koppelaars on Oct 1, 2009 5:55 PM

  • ORA-24777 when trying to call multiple Oracle SPs...

    I had a SP in Oracle that called another SP in a SQL Server DB via DBLink. I was calling the Oracle SP from VB.NET (3.5) and because of transaction commiting I was not able to do this, so I removed the SQL SERVER SP call from inside the Oracle SP. However, I still get a ORA-24777 error: use of non-migratable database link not allowed.
    If I removed the reference to the other DB, why would I still get an error referencing the DBLINK?
    I'm using Oracle 10.2 and VB.NET (3.5).
    old SP CODE:
    I have a package called USP_VALIDATION
    In the package body, I was calling BATCH(Queue, RefNo) [a procedure in USP_VALIDATION]
    In this BATCH procedure, I would call SP_GET_BILLING_OPTION_TCIS(accNo, lclBillingOption) [note TCIS is the SQL DB and lclBillingOption would be the TCIS billing option]
    ... do something with lclBillingOption
    I changed this to the following:
    In the package body, I now call BATCH(Queue, RefNo, BillingOption)
    In this new BATCH procedured, I now DON'T call SP_GET_BILLING_OPTION_TCIS as I already retrieved it first before I call USP_VALIDATION in the .NET code
    ... do something with the BillingOption passed in as a parameter when calling BATCH.
    What I'm really trying to do is make sure that the transaction commitment/rollback is handled correctly in the following senario.
    What happened before was because the one SP was calling another SQL database via DBLINK, it was not working correctly. So we removed the DBLINK and now call the SQL database before we do any action with the Oracle SPs.
    Here is my code in .NET:
    Public Function EnrollElectricCustomer(ByVal EnrollParameters As IEnrollmentParameters) As IEnrolleSearch Implements Interfaces.IEnrollmentManager.EnrollElectricCustomer
            Dim dacRCES As New Dac.RC.EnrolleeDataService()
            Dim dacRCAS As New Dac.RC.AccountDataService()
            Dim oServiceType As IServiceType = New ServiceType(ServiceTypeEnum.Gas)
            Dim dacCSS As New Dac.Css.CssCustomerAccount
            Dim oBillingOption As IBillingOption = Nothing
            Dim business As New AccountManager
            Dim WorkQID As Long = 0
            Dim enrolleeSearch As EnrolleeSearch = Nothing
            Dim MainTranScope As TransactionScope = New TransactionScope(TransactionScopeOption.RequiresNew)
            Try
                EventLog.WriteEntry("RCIS", "Access --> EnrollElectricCustomer")
                ' comment - here I go to SQL Server to get the Billing Option instead of doing it thru DBLINK
                oBillingOption = dacRCAS.GetCurrentBillingOption(EnrollParameters.CssAccountNumber, oServiceType)
                Using MainTranScope
                    'first save the Enrollment record to the Enroll Queue
                    WorkQID = dacRCES.SaveElectricEnrollee(EnrollParameters)
                    'need to put account number needed into a collection
                    Dim oColAccounts As New Generic.List(Of IAccountRefreshRequests)
                    Dim oColCSSAccounts As New Generic.List(Of ICustomerAccount)
                    Dim oAccount As New AccountRefreshRequests
                    Dim oCustomerAccount As ICustomerAccount
                    Dim refreshstring As String = String.Empty
                    oAccount.CSSAccountNumber = EnrollParameters.CssAccountNumber
                    oAccount.CSSAccountNumberNoCheckDigit = EnrollParameters.CssAccountNumber.Substring(0, 14)
                    oAccount.CSSCheckDigit = EnrollParameters.CssAccountNumber.Substring(14, 1)
                    oAccount.ServiceType.CodeString = "E"
                    Dim rStatus As New RefreshStatus
                    rStatus.Code = StatusEnum.NewAccount
                    oAccount.Status.CodeString = rStatus.CodeString()
                    oColAccounts.Add(oAccount)
                    'call CSS passing in collection of account(s) and returning back collection of account(s)
                    oColCSSAccounts = dacCSS.GetCssAccountInfo(oColAccounts)
                    oCustomerAccount = New CustomerAccount
                    oCustomerAccount = oColCSSAccounts.Item(0)
                    refreshstring = business.BuildRefreshString(oCustomerAccount)
                    dacRCES.RefreshElectricAccount(refreshstring)
                    'once refreshed, we need to also run VALIDATION on this enrollent record...
    *' NOTE THAT THIS SP used to CALL SQL via DBLINK but no longer does....*               
                    dacRCES.ValidateElectricEnrollment(WorkQID,oBillingOption)
                    'once validated, we also have to submit the record....
                    dacRCES.SubmitElectricEnrollment(WorkQID)
                    MainTranScope.Complete()
                End Using
                If WorkQID > 0 Then
                    'now we need to retrieve the account enrollment record...
                    enrolleeSearch = dacRCES.FindEnrolleeByEnrollID(WorkQID, ServiceTypeEnum.Electric)
                End If
            Catch ex As Exception
                SendEmail.SendErrorEmail("EnrollElectricCustomer --> " & EnrollParameters.CssAccountNumber, ex.Message)
                RcCommon.WriteExceptionToLog(ex)
                Throw
            End Try
            Return enrolleeSearch
        End FunctionI'm concerned that if any one of the various calls fails, I want to rollback the ENTIRE transaction. Right now I
    a) insert the row into a table in Oracle,
    b) get detailed information on this account from another database (DB2),
    c) refresh the data in the Oracle DB on this account,
    d) validate the record added (business rules) and then when all done,
    e) to submit the account (which changes statuses for later use).
    If I insert the record but it fails at step d say, I want to rollback everything and remove the record from the Oracle table...
    Edited by: userLynx on Oct 17, 2012 6:37 AM

    EDIT1:
    You posted an edit including code while I was typing original response.
    You may find the following My Oracle Support note helpful. It applies to ODP.NET as well.
    ORA-24777 When Selecting Across a Database Link With Microsoft OLE DB Provider for Oracle [ID 397555.1]
    Just to confirm - is the database link used at all now?
    I know you said that the stored procedure is no longer called, but is the link still used for anything else?
    Also, do you have a call stack from when the exception is raised?
    Edited by: Mark Williams on Oct 17, 2012 9:53 AM

  • Error when calling a package function

    any insight why my object is erroring out when calling a function. the error is
    oracle.apps.fnd.framework.OAException: java.sql.SQLException: ORA-06502: PL/SQL: numeric or value error: character to number conversion error
    ORA-06512: at line 1
    it errors out when the cs.execute() is . is it the placement ? thanks for the help....
    then pkg func is xxx.get_log
    Get_Log(rmode IN NUMBER , doc_type IN VARCHAR2 DEFAULT 'TEL', doc_id IN VARCHAR2 DEFAULT NULL,
    doc_num IN VARCHAR2 DEFAULT NULL -- , p_out out varchar2 --
    RETURN varchar2 IS....
    the co
    Serializable paramDocLocatorParamList [] = {paramRMODE, paramDOC_TYPE, paramDOC_ID, paramDOC_NUM, p_out };
    OAApplicationModule am = (OAApplicationModule)pageContext.getApplicationModule(webBean);
    OADBTransaction dbtrans;
    OAViewObject docLocator = (OAViewObject)am.findViewObject("DocLocatorVO1");
    rtxt0.setValue(pageContext, "here it is" + am.invokeMethod("getHTMLString", paramDocLocatorParamList));
    docLocator.executeQuery();
    // am.invokeMethod("getHTMLString", paramDocLocatorParamList);
    the impl
    public String getHTMLString ( String paramRMODE, String paramDOC_TYPE, String paramDOC_ID, String paramDOC_NUM, String p_out )
    System.out.println("Entering The AM Impl");
    CallableStatement st = null;
    OADBTransaction txn = (OADBTransaction)getDBTransaction();
    Connection conn = txn.getJdbcConnection();
    String sql = " BEGIN :5 := test_proc.get_log(:1, :2, :3, :4 ); END; ";
    CallableStatement cs = txn.createCallableStatement(sql,1);
    String ErrorExist = "";
    String getHTML = "";
    try
    cs.setString(1, paramRMODE);
    cs.setString(2, paramDOC_TYPE);
    cs.setString(3, paramDOC_ID);
    cs.setString(4, paramDOC_NUM);
    cs.setString(5,p_out); // --param   
    /* cs.registerOutParameter(1,Types.CHAR);
    cs.registerOutParameter(2,Types.CHAR);
    cs.registerOutParameter(3,Types.CHAR);
    cs.registerOutParameter(4,Types.CHAR);*/
    cs.registerOutParameter(5,Types.CHAR);
    cs.execute();
    getHTML = cs.getString(5 ) ;
    /* System.out.println("getHTML is " + getHTML );
    cs.close();
    // if ( "E".equals(ErrorExist))
    /// throw new OAException ("Payment Request Is Already Cancelled" );
    catch (SQLException sqle)
    try { cs.close(); }
    catch (Exception e) {}
    throw OAException.wrapperException(sqle);
    String doctype = paramDOC_TYPE;
    String docnum = paramDOC_NUM;
    String html ;
    System.out.println( "paramDOC_TYPE in IMPL is " + doctype) ;
    System.out.println( "paramDOC_Numb in IMPL is " + docnum) ;
    return getHTML;

    resolved.....
    public String getHTMLString (String p_out , String rmode, String doc_type, String doc_id, String doc_num )
    System.out.println("");
    System.out.println("Entering The AM Impl");
    // System.out.println("Passing getDocAbbrForHTML in IMPL -------> " +getDocAbbrForHTML     );
    // System.out.println("Passing paramDOC_NUM in IMPL -------> " + paramDOC_NUM );
    System.out.println("Passing getDocAbbrForHTML in IMPL -------> " +doc_type     );
    System.out.println("Passing paramDOC_NUM in IMPL -------> " + doc_num );
    CallableStatement st = null;
    OADBTransaction txn = (OADBTransaction)getDBTransaction();
    Connection conn = txn.getJdbcConnection();
    String sql = " BEGIN :1 := test_proc.get_log(:2, :3, :43, :5 ); END; ";
    CallableStatement cs = txn.createCallableStatement(sql,1);
    String ErrorExist = "";
    String getHTML = "";
    try
    cs.setString(2, rmode);
    cs.setString(3, doc_type);
    cs.setString(4, doc_id);
    cs.setString(5, doc_num);
    cs.registerOutParameter(1,Types.VARCHAR);
    cs.execute();
    getHTML = cs.getString(1 ) ;

  • How to set the root path of XML document when calling Inserting procedure

    Hi,
    I was create a procedure to insert XML Document in to DBMS Tables, but i am not able to set the Start root element in calling procedure.
    My calling procedure is
    exec insXmldoc('pmc_sample.xml', 'pmc')
    When i am calling this procedure i got this error
    11:23:54 Error: ORA-29532: Java call terminated by uncaught Java exception: oracle.xml.sql.OracleXMLSQLException: Start of root element expected.
    ORA-06512: at "SYS.DBMS_XMLSAVE", line 65
    ORA-06512: at "SCOTT.INSPROC", line 8
    ORA-06512: at line 2
    I am checking my XML file using XML Validator. My XML file was parsed with out errors.
    Please give the solution,and tell me where i did wrong in my calling procedure.
    suppose i have this XML file in local E drive ,how to set the path for that XML file in my calling procedure.

    Hi, I am doing the code likthis,please give the solution.
    SQL> create or replace procedure insProc(xmlDoc IN CLOB, tableName IN VARCHAR2) is
    2 insCtx DBMS_XMLSave.ctxType;
    3 l_ctx dbms_xmlsave.ctxtype;
    4 rows number;
    5 begin
    6 insCtx := DBMS_XMLSave.newContext(tableName); -- get the context handle
    7 rows := DBMS_XMLSave.insertXML(insCtx,xmlDoc); -- this inserts the document
    8 DBMS_XMLSave.closeContext(insCtx); -- this closes the handle
    9 end;
    10 /
    Procedure created.
    SQL> begin
    2 insProc('/usr/tmp/ROWSET.xml', 'emp');
    3 end;
    4 /
    begin
    ERROR at line 1:
    ORA-29532: Java call terminated by uncaught Java exception: oracle.xml.sql.OracleXMLSQLException:
    Start of root element expected.
    ORA-06512: at "SYS.DBMS_XMLSAVE", line 65
    ORA-06512: at "SCOTT.INSPROC", line 7
    ORA-06512: at line 2
    Kishore B

Maybe you are looking for

  • Vendor master data file structure

    Hello Guys, I want to knw the flat file strucute of vendor master data (specially vendor with multiple banks) pls let me knw tht thnks sunny

  • Display all levels in Cash Flow Report (FF7A)

    Hi all, I am new to FF7A and I would like to get all levels of my different grouping levels to appear on one screen. I can't figure how to do it. So far I can see BANKEN and PERSONEN and drilldown in each of them but can't get to see the details of b

  • WAAS: Standard vs Extended ACL's for WCCP Transparent Redirection

    I've come across a number of implementations where the ACL's associated with services 61 & 62 are using extended access-list. I am writing with specific reference to wccp configured in promiscuous mode. Since WCCP will only redirect TCP, and the WAAS

  • Is Apache OpenOffice 4.0.1 safe to download?

    I have OpenOffice 3.3.0 installed from several years ago and wish to update to Apache OpenOffice 4.0.1 and wish to know if this is safe and will a download be stopped by Gatekeeper which is set to accept "Mac App Store and identified developers"? Are

  • When i turn my ipod on it said use itunes to restore......

    when i turn my ipod on it said use itunes to restore. SO i downloaded the new itunes (7.2 i think) and when i pluged ipod in it said ipod in recovery mode restore before use in itunes for sumthin like that... so i did that and at the end it said erro