ORA-302000 Error On client_text_io.fopen()

i am using a webutil library - client_text_io.fopen() on the form that was compiled on 10.1.2.3 version and this webutil_file.file_selection_dialog() built-in package. the webutil_file.file_selection_dialog() works but not the client_text_io.fopen(). when the form is run on the application server it is getting this error ORA-302000.
PROCEDURE prc_load_proj_alloc_data IS
  vFilename             VARCHAR2(100) := :control.drv_filename;
  vInputFile             client_text_io.FILE_TYPE;
  vLinebuf               VARCHAR2(2000);
  vCommaPosition     NUMBER := 0;
  TYPE                array_type IS VARRAY(10) OF VARCHAR2(100);
  vColumn            array_type := array_type('');
  vCtr                  BINARY_INTEGER := 1;
  vRowCtr            number := 0;
  vLineLoadCnt     number := 0;
begin
  -- cursor must be placed on the block
  go_block('MRC_PROJ_ALLOC_INTERFACE');
  go_item('MRC_PROJ_ALLOC_INTERFACE.ATTRIBUTE1'); 
  --extend and initialize the array to 9 columns
  vColumn.EXTEND(9,1);
  -- open the file for reading
  begin
    vInputFile := client_text_io.fopen(vFilename,'r');
  exception
       when others then
         alertme('note','SQLCODE '||SQLCODE);
         if SQLCODE = -302000 then
              alertme('note',errtyp||'-'||TO_CHAR(errnum)||': '||errtxt);
        loop
          alertme('note',TO_CHAR(TOOL_ERR.CODE) || ': ' || TOOL_ERR.MESSAGE);
          TOOL_ERR.POP;
          exit when TOOL_ERR.NERRORS = 0;
        end loop;
      end if;
  end;
end;
    the file that i am trying to read is in csv format and is not currently in use. i tried any other file from my local C:\ or D:\ drive and i am getting the same error. what could possiblly that i am missing? thanks.

we figured it out that the cause of issue was that the webutil.plx was on our application executable directory. basically we have the webutil.plx on a common directory applicable to other application and when we removed the webutil.plx on our application directory the ORA-302000 error was solved.

Similar Messages

  • ORA-302000 error

    I am getting a error ORA-302000 which is not showing in Oracle documentation help from my Developer form. Please help.
    regards.

    we figured it out that the cause of issue was that the webutil.plx was on our application executable directory. basically we have the webutil.plx on a common directory applicable to other application and when we removed the webutil.plx on our application directory the ORA-302000 error was solved.

  • URGENT : ORA 302000 when using TEXT_IO.fopen

    Hi,
    I get this error ORA 302000 when using TEXT_IO package, the code I use is
    new_file:=text_io.fopen('c:\text.txt','r')
    i don't have the description of this ORA 302000 , pls does anyone have it?

    Hi,
    I know it's been 2 years but it's still up to date for me.
    I tried the suggested piece of code to trace the error but it did not bring anything more
    EXCEPTION
    When Others then
    srw.Message( 2, 'EXCEPTION ' || SQLCODE || ' in common package. Can not open the file ');
    IF SQLCODE = -302000 then
    LOOP
    EXIT WHEN TOOL_ERR.NERRORS = 0;
    SRW.MESSAGE( 667, TO_CHAR(TOOL_ERR.CODE) || ': ' || TOOL_ERR.MESSAGE);
    TOOL_ERR.POP;
    END LOOP;
    END IF;
    srw.Message( 3, 'EXCEPTION ' || SQLCODE || ' in com package. Can not open the file ' || I_Desname || ' : ' || SQLERRM );
    Only Message 2 and 3 are displayed in the trace file
    Any other suggestion?
    Manu

  • A text_io problem: ORA-302000

    Hi,all:
    I have 2 apps on form.
    The first one is to read from file, and the second is to write on the file.
    Firstly, i have created the file on the server, and the file(abc.txt)'s permission is rwxr--r--.
    Then i tested the first one, it can read from file well.
    But when i tested the second, it throwed a exception: ORA-302000.
    I was so confused. why it can read from file with text_io, but can not write?
    Can anyone help me to solve this problem, Thanks so much.
    Here's my code:
    1.WHEN-BUTTON-PRESSED(to read): works fine
    DECLARE
         in_file text_io.file_type;
         line_bufer varchar2(80);
         lv_strtmp varchar2(100);
         errnum NUMBER                := ERROR_CODE;
         errtxt VARCHAR2(80) := ERROR_TEXT;
         errtyp VARCHAR2(3)      := ERROR_TYPE;
    BEGIN
         in_file := text_io.fopen('/home/cn01278/abc.txt', 'r');
         text_io.Get_Line(in_file,line_bufer);
         lv_strtmp := substr(line_bufer, 1,10);
         :blk_text.txt_content := :blk_text.txt_read_err || lv_strtmp;
         text_io.Fclose(in_file);
    END;
    2.WHEN-BUTTON-PRESSED(to write): thown an exception
    DECLARE
              out_file text_io.file_type;
              line_bufer varchar2(80);
              lv_strtmp varchar2(100);
              lv_content varchar2(100);
              errnum NUMBER := ERROR_CODE;
              errtxt VARCHAR2(80) := ERROR_TEXT;
              errtyp VARCHAR2(3) := ERROR_TYPE;
    BEGIN
         message('111',acknowledge);
              out_file := text_io.fopen('/home/cn01278/abc.txt', 'w');
              message('222',acknowledge);
              text_io.put('123');
              text_io.new_line;
              text_io.put_line(out_file, 'abcd...');
         text_io.fclose(out_file);
    END;
    3.ON-ERROR Trigger
    DECLARE
         errnum NUMBER := ERROR_CODE;
         errtxt VARCHAR2(80) := ERROR_TEXT;
         errtyp VARCHAR2(3) := ERROR_TYPE;
    BEGIN
    message('error:',acknowledge);
         Message(errtyp||'-'||TO_CHAR(errnum)||': '||errtxt,acknowledge);
         --:blk_text.txt_err := errtyp||'-'||TO_CHAR(errnum)||': '||errtxt;
         text_io.fclose(out_file);
         RAISE Form_Trigger_Failure;
    END;
    -----------------------------------------------------------------------------------

    Thanks for attension.
    the problem is resolved, it's a access/right problem with the file(abc.txt).
    after i change the file permission from rwxr--r-- to rwxrw-rw-, then it works fine.
    But I have some confuse about it.
    1.The file must exist firstly. if not, then read or wirte the file will cause the ORA-302000 error. Can the file not exist? Can anyone tell me how to create file(abc.txt) with text_io if the file not exist.
    2.If the file was created by A, and A have rw rights, but the group owner have no rw rights, then you run the form by A(connect DB by A), it would cause ORA-302000 error too(both read and write).Why the group owner must have rw rights, or the form can not works fine?
    By the way, my DB account and my App server(Linux) account are same(both A).

  • CLIENT_TEXT_IO.fopen will not work Error

    I keep getting the following -
    WebUtil Error: oracle.forms.webutil.file.FileFunctions bean not found. CLIENT_TEXT_IO.fopen will not work.
    Nothing I have found on any forum threads has helped me resolve this issue. I believe it has to do w/ configuration. The error occurs in my Development Suite environment I have set up on my laptop. The webutil set up on the Application Server seems to be fine.
    I've checked both default.env and formsweb.cfg and both seem to be set correctly. I have the webutil.pll attached to the forms and the webutil.olb in the object library.
    I'm using WebUtil 1.0.6 on Oracle 10g (9.0.4).
    If anyone has any guidance on this issue, your help is appreciated.

    The error isn't obvious. The Java Console outputs the following. I went through the webutil docs again and still didn't get the issue resolved. Can you help?
    Oracle JInitiator: Version 1.3.1.17
    Using JRE version 1.3.1.17-internal Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\localadmin
    Proxy Configuration: no proxy
    JAR cache enabled
    Location: C:\Documents and Settings\localadmin\Oracle Jar Cache
    Maximum size: 50 MB
    Compression level: 0
    Loading http://server.domain.com:8889/forms90/java/f90all_jinit.jar from JAR cache
    proxyHost=null
    proxyPort=0
    connectMode=HTTP, native.
    Forms Applet version is : 9.0.4.0
    java.lang.ClassNotFoundException: java.io.IOException: open HTTP connection failed.
         at sun.applet.AppletClassLoader.getBytes(Unknown Source)
         at sun.applet.AppletClassLoader.access$100(Unknown Source)
    at sun.applet.AppletClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
         at sun.applet.AppletClassLoader.findClass(Unknown Source)
         at sun.plugin.security.PluginClassLoader.findClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at sun.applet.AppletClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClassInternal(Unknown Source)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Unknown Source)
         at oracle.forms.handler.UICommon.instantiate(Unknown Source)
         at oracle.forms.handler.UICommon.onCreate(Unknown Source)
         at oracle.forms.handler.JavaContainer.onCreate(Unknown Source)
         at oracle.forms.engine.Runform.onCreateHandler(Unknown Source)
         at oracle.forms.engine.Runform.processMessage(Unknown Source)
         at oracle.forms.engine.Runform.processSet(Unknown Source)
         at oracle.forms.engine.Runform.onMessageReal(Unknown Source)
         at oracle.forms.engine.Runform.onMessage(Unknown Source)
         at oracle.forms.engine.Runform.sendInitialMessage(Unknown Source)
         at oracle.forms.engine.Runform.startRunform(Unknown Source)
         at oracle.forms.engine.Main.createRunform(Unknown Source)
         at oracle.forms.engine.Main.start(Unknown Source)
         at sun.applet.AppletPanel.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)

  • Error WUC-14 after open a File with CLIENT_TEXT_IO.FOPEN (Oracle 10g)

    Hi,
    the error WUC-14 occurs during open a file with forms10g.
    F_VersandZahlen := CLIENT_TEXT_IO.FOPEN (F_Dateiname,'w');
    Afterwards the error message it ist possible to write into the file and close it correctyl (without am error message - also the Information is correkt).
    During debugging the error occurs in the function GETPROPERTY (Webutil).
    the error occurs only sometimes.
    Can anybody help me to solve the problem ?
    best regards,
    Alexandra Schermann

    Hi Alexandra,
    You can catch the exception in Exceptions part and close the file. Something like,
    DECLARE
    F_VersandZahlen CLIENT_TEXT_IO.FILE_TYPE;
    BEGIN
    F_VersandZahlen := CLIENT_TEXT_IO.FOPEN (F_Dateiname,'w');
    <do your processing>
    EXCEPTION
      WHEN OTHERS THEN
       CLIENT_TEXT_IO.FCLOSE(F_VersandZahlen);
    END;-Arun

  • Error WUC-14 after CLIENT_TEXT_IO.FOPEN

    Hi,
    the error WUC-14 occurs during open a file with forms10g.
    F_VersandZahlen := CLIENT_TEXT_IO.FOPEN (F_Dateiname,'w');
    Afterwards the error message it ist possible to write into the file and close it correctyl (without am error message - also the Information is correkt).
    During debugging the error occurs in the function GETPROPERTY (Webutil).
    the error occurs only sometimes.
    Can anybody help me to solve the problem ?
    best regards,
    Alexandra Schermann

    Sounds like an Oracle Forms question... there is a dedicated forum for Forms. Maybe answer your question there.
    Forms
    Edited by: Alex Nuijten on Oct 27, 2009 11:08 AM

  • How to use Linux Print queue in client_text_io.fopen to print from Windows

    We have a forms application deploed on LINUX (Oracle application server 10g).
    I have to print a file from local windows PC to a linux Print Queue from forms
    I have the following code
    PROCEDURE file_to_printer (i_filename_output IN VARCHAR2
    ,i_network_printer IN VARCHAR2) IS
    l_line VARCHAR2(2000);
    l_fileid_output client_text_io.file_type;
    l_fileid_print client_text_io.file_type;
    BEGIN
    l_fileid_output := client_text_io.fopen (i_filename_output,'R');
    l_fileid_print := client_text_io.fopen (i_network_printer,'W');
    WHILE 1 = 1 LOOP
    client_text_io.get_line (l_fileid_output, l_line);
    client_text_io.put_line (l_fileid_print, l_line);
    END LOOP;
    EXCEPTION
    WHEN NO_DATA_FOUND THEN
    client_text_io.fclose (l_fileid_output);
    client_text_io.fclose (l_fileid_print);
    END file_to_printer;
    Everything works fine if I use a windows printer like \\machine\printer.
    I want to use a Linux printer and specified the print queue as
    \\machine\print_queue_name. It's not working
    and I get error ORA-302000 on the following line
    l_fileid_print := client_text_io.fopen (i_network_printer,'W');
    and if I give only the queue name no error but it's not printing.
    Could you please tell me how to use a Linux/Unix print queue in this situation

    the simplest way is to edit the interface file (look in /etc/lp/interfaces for existing printers). Each script is
    run per print job where stdin has your print data, and stdout is going to your print device. You can just
    send the output to a file instead (assuming you can create a file in the windows directory from the solaris
    box). If it's a network share, you could use smbclient.
    -r

  • Client_text_io.fopen causes java.lang.NullPointerException

    Hi all
    I have the following very simple snippet of code:
    declare
         f client_text_io.file_type;
    begin
         f := client_text_io.fopen('C:\test.txt', 'r');
    end;
    If "C:\Test.txt" does NOT exist on the client, Webutil correctly pops up and complains "Can't open file" etc. But... when the file actually exists and is ready to be opened for read, the following exception is thrown in the console, and nothing happens:
    java.lang.NullPointerException: charsetName
         at java.io.InputStreamReader.<init>(Unknown Source)
         at oracle.forms.webutil.file.FileFunctions.fopen(Unknown Source)
         at oracle.forms.webutil.file.FileFunctions.getProperty(Unknown Source)
         at oracle.forms.handler.UICommon.onGet(Unknown Source)
         at oracle.forms.engine.Runform.onGetHandler(Unknown Source)
         at oracle.forms.engine.Runform.processMessage(Unknown Source)
         at oracle.forms.engine.Runform.processSet(Unknown Source)
         at oracle.forms.engine.Runform.onMessageReal(Unknown Source)
         at oracle.forms.engine.Runform.onMessage(Unknown Source)
         at oracle.forms.engine.Runform.processEventEnd(Unknown Source)
         at oracle.ewt.lwAWT.LWComponent.redispatchEvent(Unknown Source)
         at oracle.ewt.lwAWT.LWComponent.processEvent(Unknown Source)
         at java.awt.Component.dispatchEventImpl(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Window.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.run(Unknown Source)
    2006-feb-23 10:36:18.653 ERROR>WUC-15 [FileFunctions.fopen()] Uventet fejl, undtagelse: java.lang.NullPointerException: charsetName
    I have no idea, what goes wrong here.... can anyone help? I use Sun JPI 1.5 on the client.
    Thanks in advance.

    Hi all
    I have forms 9.0.4.6 and Webutil 1.0.6
    When I use client_text_io.fopen like this:
    declare
    f client_text_io.file_type;
    begin
    f := client_text_io.fopen('C:\test.txt', 'r');
    end;
    I get an error:
    ERROR>WUC-15 [FileFunctions.fopen()] Unexpected error, Exception: java.lang.NullPointerException
    java.lang.NullPointerException
         at sun.io.Converters.getConverterClass(Unknown Source)
         at sun.io.Converters.newConverter(Unknown Source)
         at sun.io.ByteToCharConverter.getConverter(Unknown Source)
         at java.io.InputStreamReader.<init>(Unknown Source)
         at oracle.forms.webutil.file.FileFunctions.fopen(FileFunctions.java:413)
         at oracle.forms.webutil.file.FileFunctions.getProperty(FileFunctions.java:188)
         at oracle.forms.handler.UICommon.onGet(Unknown Source)
         at oracle.forms.engine.Runform.onGetHandler(Unknown Source)
         at oracle.forms.engine.Runform.processMessage(Unknown Source)
         at oracle.forms.engine.Runform.processSet(Unknown Source)
         at oracle.forms.engine.Runform.onMessageReal(Unknown Source)
         at oracle.forms.engine.Runform.onMessage(Unknown Source)
         at oracle.forms.engine.Runform.processEventEnd(Unknown Source)
         at oracle.ewt.lwAWT.LWComponent.redispatchEvent(Unknown Source)
         at oracle.ewt.lwAWT.LWComponent.processEvent(Unknown Source)
         at java.awt.Component.dispatchEventImpl(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Window.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.run(Unknown Source)
    Could anybody help me? I really need to use this.

  • Webutil - client_text_io.fopen

    Hi!
    I have a problem. My database charset is EE8ISO8859P2 (SELECT * FROM v$nls_parameters) and I use AS for 10g. I also installed webutil 1.0.6 and I call function client_text_io.fopen(p_file,'W','WINDOWS-1250'); When I write to file I use client_text_io.put_line(p_file,p_text). This file I write to is xml file.
    In variable p_text are letters like &#269;, š, ž (Slovenian language), but when I look at the file I created there are no letters I mentioned above. Instead of &#269; is blank, instead of š is a, etc.
    What should I do? I would like to solve this problem, without writing to AS (text_io) and then use transfer to client.
    Does anyone have solution for this problem. It's very urgent.
    Thanks.
    Bojan

    I'm just curious here as to why you should get this error at all. How come the upload directory does not exist. The only way I can see this happening is if you allow the end users to say where they want to upload to which is very dangerous. In any case, if the upload location may not exist then you might be wise to write some PL/SQL to check this before you even attempt the upload. A Simple Text_io call to write a test file in the directory in question will check that you a) Have the directory and b) can write to it.

  • FRM-92101 client_Text_IO.Fopen Urgent

    FRM-92101 client_Text_IO.Fopen
    Posted: Sep 22, 2006 1:25 AM Reply
    Hello
    Following OAS was installed:
    · Oracle Application Server 10g Release 1 (9.0.4.0.0)
    · Oracle Application Server Patchset 3 for OAS 9.0.4, therefore the actual
    I have a problem
    when I try to start my application who create a text file on the client site my application crash. client_Text_IO.Fopen (webutil)
    This is the code line where the application crash.
    l_out_file := client_Text_IO.Fopen(fname, 'W');
    Thanks in advance for your help.
    Best regards
    Sébastien
    The Oracle Error is FRM-92101
    La version Forms Applet est : 9.0.4.3
    oracle.forms.net.ConnectionException: Forms session <448> aborted: unable to communicate with runtime process.
    at oracle.forms.net.ConnectionException.createConnectionException(Unknown Source)
    at oracle.forms.net.HTTPNStream.getResponse(Unknown Source)
    at oracle.forms.net.HTTPNStream.doFlush(Unknown Source)
    at oracle.forms.net.HTTPNStream.flush(Unknown Source)
    at java.io.DataOutputStream.flush(Unknown Source)
    at oracle.forms.net.StreamMessageWriter.run(Unknown Source)
    java.io.EOFException
    at java.io.DataInputStream.readUnsignedByte(Unknown Source)
    at oracle.forms.engine.Message.readDetails(Unknown Source)
    at oracle.forms.engine.Message.readDetails(Unknown Source)
    at oracle.forms.net.StreamMessageReader.run(Unknown Source)

    Are you sure you have properly installed and configured webutil?

  • ORA-907 ERROR WHEN IMPORT (COMMENT 처리)

    제품 : ORACLE SERVER
    작성날짜 : 1997-10-15
    ORA-907 ERROR WHEN IMPORT (COMMENT 처리)
    ========================================
    ORA-907: missing right parenthesis error
    이 error 는 export 한 table 을 create 시 comment 를 사용한 경우 발생하는 ORACLE error 이다.
    이는 version 8.0.4 에서 fix 되었다.
    이를 해결하기 위해서는 미리 table create script 를 돌려 temp_table 을
    create 하십시오.
    이 때 comment 를 모두 뺀 상태로 create 한다. 또는 /* */ 는 괜찮다.
    이후 INSERT INTO temp_table select * from original_table ;
    을 실행합니다.
    즉 original_table 을 temp_table 로 copy 한 후
    drop table original_table;
    rename temp_table to original_table ;
    을 한 후 table을 다시 export해서 다른 machine으로 import한다.
    또 이 -- 를 없애는 방법으로 아래의 C program을 이용할 수 있다.
    /* file name : cnvt_dmp.c
    * This program is to covert double dash remark expression
    * C language stype remark expression.
    #include <stdio.h>
    #define MAXWORDS 4
    char s_reserve[4][100]={ "NOT NULL", "CONSTRAINTS",")",","};
    int dash2remark();
    void main(argc,argv)
    int argc;
    char *argv[];
    FILE f_in, f_out;
    int i,j,lreserve;
    int chr1,chr2;
    char str1[100],str2[100],str3[100];
    if( argc != 3 ) {
    printf(" usage : cnvt_dmp infile.dmp outfile.dmp \n");
    exit(0);
    if( (f_in = fopen(argv[1],"r")) == NULL ) {
    printf("could't open the source file.: %s\n",argv[1]);
    exit(0);
    if( (f_out = fopen(argv[2],"w")) == NULL ) {
    printf("대상화일을 생성할 수가 없습니다.\n");
    exit(0);
    j = i = 0;
    while( (chr1 = fgetc(f_in)) != EOF && !ferror(f_in)) {
    if( chr1 == 'D' ) {
    str1[0]='D';
    fputc(chr1, f_out) ;
    for(i=1;i<7;i++) {
    chr1 = fgetc(f_in);
    str1[i] = chr1;
    fputc(chr1, f_out) ;
    str1[7] = 0;
    strcpy( str2,"DEFAULT");
    if ( strcmp( "DEFAULT",str1) == 0 ) {
    lreserve = 0;
              i =0;
    while( (chr2 = fgetc(f_in))!= ','){
    if ( chr2 == ')') break;
    str2[i] = chr2;
    if ( chr2 == '-' )
    lreserve = 1;
              i++;
    str2[i] = chr2;
    str2[i+1] = 0;
    printf(" lreserv => %d, str2=>%s\n",lreserve,str2);
    if (lreserve) {
    dash2remark(f_in,f_out,str2);
    else {
    for( i=0;i<strlen(str2);i++) fputc(str2,f_out);
    else {
    fputc(chr1, f_out );
    fclose(f_out);
    fclose(f_in);
    return;
    int dash2remark( f_in,f_out,str)
    FILE f_in,f_out;
    char *str;
    int i,j,start_pos=-1,end_pos=-1;
    for( i=0; i < strlen(str); i++ ) {
    if ( str[i] == '-') {
    start_pos = i;
    for( j =0 ; j < MAXWORDS; j++){
    if (strncmp(s_reserve[j],str+i,strlen(s_reserve[j]))== 0){
    end_pos = i;
    if ( start_pos > 0 ) {
    for(i=0;i< (start_pos-1); i++)
    fputc( str[i],f_out);
    fputc('/',f_out); fputc('*',f_out);
    for(i =i+2;i<(end_pos-1);i++)
    fputc(str[i],f_out);
    fputc('*',f_out); fputc('/',f_out);fputc(' ',f_out);
    for(i;i<strlen(str);i++)
    fputc(str[i],f_out);
    else {
    for(i=0;i<strlen(str);i++)
    fputc(str[i],f_out);
    return(1);
    이상입니다.

    Hi, i think that the problem is around the rollback segments.The solution is bring other rollback segments ONLINE state, if not exist others rollbackup,then you need create the other rollback segments and bring online state.
    If you need more information, you will must see the next DOC-ID on Metalink site,
    Note:121971.1
    Luck.
    Have a good day.
    Regards.

  • Very weird ORA-06502 error while creating procedure

    Hi All,
    i try to create the following procedure (on a 10.2 database):
    create or replace procedure audit_report
    as
    cursor c_audit_user (b_start_date date, b_end_date date)
    is
    select user_id
    , os_user
    , session_id
    , host
    , last_program
    , last_action
    , last_module
    , to_char(logon_day,'dd-mm-yyyy') logon_day
    , logon_time
    , to_char(logoff_day,'dd-mm-yyyy') logoff_day
    , logoff_time
    , elapsed_minutes
    from audit_user
    where logon_day >= b_start_date
    and logon_day < b_end_date
    order by logon_day desc
    cursor c_audit_ddl (b_start_date in date, b_end_date in date)
    is
    select user_name
    , to_char(ddl_date,'dd-mm-yyyy hh24:mi:ss') ddl_date
    , ddl_type
    , object_type
    , owner
    , object_name
    , sql_text
    from audit_ddl
    where ddl_date >= b_start_date
    and ddl_date < b_end_date
    order by ddl_date desc
    cursor c_audit_trail (b_start_date in date, b_end_date in date)
    is
    select os_username
    , username
    , to_char(timestamp,'dd-mm-yyyy hh24:mi:ss') timestamp
    , owner
    , obj_name
    , to_char(action) action
    , action_name
    , decode(ses_actions,'---S------------','DELETE',
    '------S---------','INSERT',
    '---------S------','SELECT',
    '----------S-----','UPDATE',
    '---S--S--S------','DELETE/INSERT/SELECT',
    '---S--S--SS-----','DELETE/INSERT/SELECT/UPDATE',
    '------S--S------','INSERT/SELECT',
    '------S--SS-----','INSERT/SELECT/UPDATE',
    '---------SS-----','SELECT/UPDATE',
    'DDL ACTION') ses_actions
    , priv_used
    from dba_audit_Trail
    where username <> 'DBSNMP'
    and timestamp >= b_start_date
    and timestamp < b_end_date
    order by timestamp desc
    v_header_user varchar2(255);
    v_sep_user varchar2(255);
    v_header_ddl varchar2(255);
    v_sep_ddl varchar2(255);
    v_header_dml varchar2(255);
    v_sep_dml varchar2(255);
    v_record_user varchar2(255);
    v_record_ddl varchar2(255);
    v_record_dml varchar2(255);
    v_report utl_file.file_type;
    v_file_dir varchar2(255);
    v_file_name varchar2(255);
    v_start_date date;
    v_end_date date;
    v_db_name varchar2(255);
    begin
    -- Find start and end date of previous week (Sunday to Monday)
    if to_char(sysdate,'DAY') = 'MONDAY' then
    v_start_date := trunc(sysdate-8);
    v_end_date := trunc(sysdate-1);
    elsif
    to_char(sysdate,'DAY') = 'TUESDAY' then
    v_start_date := trunc(sysdate-9);
    v_end_date := trunc(sysdate-2);
    elsif
    to_char(sysdate,'DAY') = 'WEDNESDAY' then
    v_start_date := trunc(sysdate-10);
    v_end_date := trunc(sysdate-3);
    elsif
    to_char(sysdate,'DAY') = 'THURSDAY' then
    v_start_date := trunc(sysdate-11);
    v_end_date := trunc(sysdate-4);
    elsif
    to_char(sysdate,'DAY') = 'FRIDAY' then
    v_start_date := trunc(sysdate-12);
    v_end_date := trunc(sysdate-5);
    elsif
    to_char(sysdate,'DAY') = 'SATURDAY' then
    v_start_date := trunc(sysdate-13);
    v_end_date := trunc(sysdate-6);
    elsif
    to_char(sysdate,'DAY') = 'SUNDAY' then
    v_start_date := trunc(sysdate-14);
    v_end_date := trunc(sysdate-7);
    end if;
    --Fill headers
    v_header_user := 'USER_ID OS_USER SESSION_ID HOST LAST_PROGR'||
    ' LAST_ACTION LAST_MODULE LOGON_DAY'||
    ' LOGON_TI LOGOFF_DAY LOGOFF_T ELAPSED_MINUTES';
    v_sep_user := '---------- --------- ---------- -------- ----------'||
    '-------------------- ----------- ----------- ---------'||
    v_header_ddl := 'USER_NAME DDL_DATE DDL_TYPE OBJECT_TYPE'||
    ' OWNER OBJECT_NAME SQL_TEXT';
    v_sep_ddl := '---------- --------------------- ---------- -----------'||
    '--------- ---------- -------------------- -------------'||
    v_header_dml := 'OS_USERNAME USERNAME TIMESTAMP OWNER'||
    ' OBJ_NAME ACTION ACTION_NAME SES_ACTIONS'||
    ' PRIV_USED';
    v_sep_dml := '----------- ---------- --------------------- ---------- '||
    '--------------- ------ --------------- ------------------'||
    --Create audit report file
    v_file_dir := 'AUDIT_REPORT_DIR';
    select name
    into v_db_name
    from v$database;
    v_file_name := 'audit_report_'||v_db_name||'_'||to_char(v_start_date,'yyyymmdd')||'-'||to_char(v_end_date-1,'yyyymmdd')||'.log';
    v_report := utl_file.fopen(v_file_dir, v_file_name, 'w');
    --Report Header
    utl_file.put_line(v_report,'AUDIT REPORT');
    utl_file.put_line(v_report,'------------');
    utl_file.put_line(v_report,'Database: '||v_db_name);
    utl_file.put_line(v_report,'From : '||to_char(trunc(v_start_date),'dd-mm-yyyy'));
    utl_file.put_line(v_report,'To : '||to_char(trunc(v_end_date),'dd-mm-yyyy'));
    utl_file.put_line(v_report,'Created : '||to_char(sysdate,'dd-mm-yyyy hh24:mi:ss'));
    utl_file.new_line(v_report);
    --Report Detail records
    utl_file.put_line(v_report,v_header_user);
    utl_file.put_line(v_report,v_sep_user);
    for r_audit_user in c_audit_user(v_start_date,v_end_date) loop
    v_record_user := rpad(r_audit_user.user_id,11,' ')||
    rpad(r_audit_user.os_user,11,' ')||
    rpad(r_audit_user.session_id,11,' ')||
    rpad(r_audit_user.host,9,' ')||
    rpad(r_audit_user.last_program,31,' ')||
    rpad(r_audit_user.last_action,12,' ')||
    rpad(r_audit_user.last_module,12,' ')||
    rpad(r_audit_user.logon_day,11,' ')||
    rpad(r_audit_user.logon_time,9,' ')||
    rpad(r_audit_user.logoff_day,11,' ')||
    rpad(r_audit_user.logoff_time,9,' ')||
    lpad(r_audit_user.elapsed_minutes,15,' ');
    utl_file.put_line(v_report,v_record_user);
    end loop;
    utl_file.new_line(v_report);
    utl_file.put_line(v_report,v_header_ddl);
    utl_file.put_line(v_report,v_sep_ddl);
    for r_audit_ddl in c_audit_ddl(v_start_date,v_end_date) loop
    v_record_ddl := rpad(r_audit_ddl.user_name,11,' ')||
    rpad(r_audit_ddl.ddl_date,22,' ')||
    rpad(r_audit_ddl.ddl_type,11,' ')||
    rpad(r_audit_ddl.object_type,21,' ')||
    rpad(r_audit_ddl.owner,11,' ')||
    rpad(r_audit_ddl.object_name,21,' ')||
    rpad(r_audit_ddl.sql_text,100,' ');
    utl_file.put_line(v_report,v_record_ddl);
    end loop;
    utl_file.new_line(v_report);
    utl_file.put_line(v_report,v_header_dml);
    utl_file.put_line(v_report,v_sep_dml);
    for r_audit_trail in c_audit_trail(v_start_date,v_end_date) loop
    v_record_dml := rpad(r_audit_trail.os_username,12,' ')||
    rpad(r_audit_trail.username,11,' ')||
    rpad(r_audit_trail.timestamp,22,' ')||
    rpad(r_audit_trail.owner,11,' ')||
    rpad(r_audit_trail.obj_name,16,' ')||
    rpad(r_audit_trail.action,7,' ')||
    rpad(r_audit_trail.action_name,16,' ')||
    rpad(r_audit_trail.ses_actions,19,' ')||
    rpad(r_audit_trail.priv_used,20,' ');
    utl_file.put_line(v_report,v_record_dml);
    end loop;
    utl_file.new_line(v_report);
    utl_file.put_line(v_report, '*** End of report ***');
    utl_file.fclose(v_report);
    end;
    This gives me the following error:
    ERROR at line 1:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-06502: PL/SQL: numeric or value error: character string buffer too small
    ORA-06512: at line 8
    When i try to create the procedure as this, i get the same error:
    create or replace procedure audit_report
    as
    /*cursor c_audit_user (b_start_date date, b_end_date date)
    is
    select user_id
    , os_user
    , session_id
    , host
    , last_program
    , last_action
    , last_module
    , to_char(logon_day,'dd-mm-yyyy') logon_day
    , logon_time
    , to_char(logoff_day,'dd-mm-yyyy') logoff_day
    , logoff_time
    , elapsed_minutes
    from audit_user
    where logon_day >= b_start_date
    and logon_day < b_end_date
    order by logon_day desc
    cursor c_audit_ddl (b_start_date in date, b_end_date in date)
    is
    select user_name
    , to_char(ddl_date,'dd-mm-yyyy hh24:mi:ss') ddl_date
    , ddl_type
    , object_type
    , owner
    , object_name
    , sql_text
    from audit_ddl
    where ddl_date >= b_start_date
    and ddl_date < b_end_date
    order by ddl_date desc
    cursor c_audit_trail (b_start_date in date, b_end_date in date)
    is
    select os_username
    , username
    , to_char(timestamp,'dd-mm-yyyy hh24:mi:ss') timestamp
    , owner
    , obj_name
    , to_char(action) action
    , action_name
    , decode(ses_actions,'---S------------','DELETE',
    '------S---------','INSERT',
    '---------S------','SELECT',
    '----------S-----','UPDATE',
    '---S--S--S------','DELETE/INSERT/SELECT',
    '---S--S--SS-----','DELETE/INSERT/SELECT/UPDATE',
    '------S--S------','INSERT/SELECT',
    '------S--SS-----','INSERT/SELECT/UPDATE',
    '---------SS-----','SELECT/UPDATE',
    'DDL ACTION') ses_actions
    , priv_used
    from dba_audit_Trail
    where username <> 'DBSNMP'
    and timestamp >= b_start_date
    and timestamp < b_end_date
    order by timestamp desc
    v_header_user varchar2(255);
    v_sep_user varchar2(255);
    v_header_ddl varchar2(255);
    v_sep_ddl varchar2(255);
    v_header_dml varchar2(255);
    v_sep_dml varchar2(255);
    v_record_user varchar2(255);
    v_record_ddl varchar2(255);
    v_record_dml varchar2(255);
    v_report utl_file.file_type;
    v_file_dir varchar2(255);
    v_file_name varchar2(255);
    v_start_date date;
    v_end_date date;*/
    v_db_name varchar2(255);
    begin
    /*-- Find start and end date of previous week (Sunday to Monday)
    if to_char(sysdate,'DAY') = 'MONDAY' then
    v_start_date := trunc(sysdate-8);
    v_end_date := trunc(sysdate-1);
    elsif
    to_char(sysdate,'DAY') = 'TUESDAY' then
    v_start_date := trunc(sysdate-9);
    v_end_date := trunc(sysdate-2);
    elsif
    to_char(sysdate,'DAY') = 'WEDNESDAY' then
    v_start_date := trunc(sysdate-10);
    v_end_date := trunc(sysdate-3);
    elsif
    to_char(sysdate,'DAY') = 'THURSDAY' then
    v_start_date := trunc(sysdate-11);
    v_end_date := trunc(sysdate-4);
    elsif
    to_char(sysdate,'DAY') = 'FRIDAY' then
    v_start_date := trunc(sysdate-12);
    v_end_date := trunc(sysdate-5);
    elsif
    to_char(sysdate,'DAY') = 'SATURDAY' then
    v_start_date := trunc(sysdate-13);
    v_end_date := trunc(sysdate-6);
    elsif
    to_char(sysdate,'DAY') = 'SUNDAY' then
    v_start_date := trunc(sysdate-14);
    v_end_date := trunc(sysdate-7);
    end if;
    --Fill headers
    v_header_user := 'USER_ID OS_USER SESSION_ID HOST LAST_PROGR'||
    ' LAST_ACTION LAST_MODULE LOGON_DAY'||
    ' LOGON_TI LOGOFF_DAY LOGOFF_T ELAPSED_MINUTES';
    v_sep_user := '---------- --------- ---------- -------- ----------'||
    '-------------------- ----------- ----------- ---------'||
    v_header_ddl := 'USER_NAME DDL_DATE DDL_TYPE OBJECT_TYPE'||
    ' OWNER OBJECT_NAME SQL_TEXT';
    v_sep_ddl := '---------- --------------------- ---------- -----------'||
    '--------- ---------- -------------------- -------------'||
    v_header_dml := 'OS_USERNAME USERNAME TIMESTAMP OWNER'||
    ' OBJ_NAME ACTION ACTION_NAME SES_ACTIONS'||
    ' PRIV_USED';
    v_sep_dml := '----------- ---------- --------------------- ---------- '||
    '--------------- ------ --------------- ------------------'||
    --Create audit report file
    v_file_dir := 'AUDIT_REPORT_DIR';
    select name
    into v_db_name
    from v$database;
    v_file_name := 'audit_report_'||v_db_name||'_'||to_char(v_start_date,'yyyymmdd')||'-'||to_char(v_end_date-1,'yyyymmdd')||'.log';
    v_report := utl_file.fopen(v_file_dir, v_file_name, 'w');
    --Report Header
    utl_file.put_line(v_report,'AUDIT REPORT');
    utl_file.put_line(v_report,'------------');
    utl_file.put_line(v_report,'Database: '||v_db_name);
    utl_file.put_line(v_report,'From : '||to_char(trunc(v_start_date),'dd-mm-yyyy'));
    utl_file.put_line(v_report,'To : '||to_char(trunc(v_end_date),'dd-mm-yyyy'));
    utl_file.put_line(v_report,'Created : '||to_char(sysdate,'dd-mm-yyyy hh24:mi:ss'));
    utl_file.new_line(v_report);
    --Report Detail records
    utl_file.put_line(v_report,v_header_user);
    utl_file.put_line(v_report,v_sep_user);
    for r_audit_user in c_audit_user(v_start_date,v_end_date) loop
    v_record_user := rpad(r_audit_user.user_id,11,' ')||
    rpad(r_audit_user.os_user,11,' ')||
    rpad(r_audit_user.session_id,11,' ')||
    rpad(r_audit_user.host,9,' ')||
    rpad(r_audit_user.last_program,31,' ')||
    rpad(r_audit_user.last_action,12,' ')||
    rpad(r_audit_user.last_module,12,' ')||
    rpad(r_audit_user.logon_day,11,' ')||
    rpad(r_audit_user.logon_time,9,' ')||
    rpad(r_audit_user.logoff_day,11,' ')||
    rpad(r_audit_user.logoff_time,9,' ')||
    lpad(r_audit_user.elapsed_minutes,15,' ');
    utl_file.put_line(v_report,v_record_user);
    end loop;
    utl_file.new_line(v_report);
    utl_file.put_line(v_report,v_header_ddl);
    utl_file.put_line(v_report,v_sep_ddl);
    for r_audit_ddl in c_audit_ddl(v_start_date,v_end_date) loop
    v_record_ddl := rpad(r_audit_ddl.user_name,11,' ')||
    rpad(r_audit_ddl.ddl_date,22,' ')||
    rpad(r_audit_ddl.ddl_type,11,' ')||
    rpad(r_audit_ddl.object_type,21,' ')||
    rpad(r_audit_ddl.owner,11,' ')||
    rpad(r_audit_ddl.object_name,21,' ')||
    rpad(r_audit_ddl.sql_text,100,' ');
    utl_file.put_line(v_report,v_record_ddl);
    end loop;
    utl_file.new_line(v_report);
    utl_file.put_line(v_report,v_header_dml);
    utl_file.put_line(v_report,v_sep_dml);
    for r_audit_trail in c_audit_trail(v_start_date,v_end_date) loop
    v_record_dml := rpad(r_audit_trail.os_username,12,' ')||
    rpad(r_audit_trail.username,11,' ')||
    rpad(r_audit_trail.timestamp,22,' ')||
    rpad(r_audit_trail.owner,11,' ')||
    rpad(r_audit_trail.obj_name,16,' ')||
    rpad(r_audit_trail.action,7,' ')||
    rpad(r_audit_trail.action_name,16,' ')||
    rpad(r_audit_trail.ses_actions,19,' ')||
    rpad(r_audit_trail.priv_used,20,' ');
    utl_file.put_line(v_report,v_record_dml);
    end loop;
    utl_file.new_line(v_report);
    utl_file.put_line(v_report, '*** End of report ***');
    utl_file.fclose(v_report);*/
    null;
    end;
    So all code is commented out, but still the error.
    Any ideas?
    Kind regards,
    Dave

    just out of interest, what output do you get if you desc user_source?
    I get:
    NAME                                               VARCHAR2(30)               
    TYPE                                               VARCHAR2(12)               
    LINE                                               NUMBER                     
    TEXT                                               VARCHAR2(4000)        

  • XMLPARSER.parseClob(v_parser, w2_data_clob); returns ORA-20100: Error

    I have a script that calls an output file and reads it into a clob. this portion seems to work fine. I next try to do a XMLPARSER.parseClob(v_parser, w2_data_clob);, but I get the following error:
    ORA-20100: Error occurred while parsing: Expected 'EOF'.
    I am attaching script and output file data. Any and all help is greatly appreciated:
    SET SERVEROUTPUT ON SIZE 100000;
    SET LINESIZE 1000;
    SET DEFINE OFF;
    DECLARE
    file_handle utl_file.FILE_TYPE;
    eof boolean := FALSE;
    retrieved_buffer VARCHAR2(2000);
    dir_name VARCHAR2(240) := cfa_lookup.meaning('APP_BASEPATH','APPLCSF') || '/out';
    file_name VARCHAR2(40) := 'o36841443.xml';
    w2_data_clob CLOB;
    w2_data_clob_out CLOB;
    v_loop_counter INTEGER := 0;
    v_parser xmlparser.parser;
    v_document xmldom.DOMDocument;
    v_length INTEGER := 0;
    v_clob_length INTEGER := 0;
    v_nodelist xmldom.DOMNodeList;
    v_node xmldom.DOMNode;
    v_new_node xmldom.DOMNode;
    v_parent_node xmldom.DOMNode;
    v_record_node XMLDOM.DOMNode;
    avalue xmldom.DOMNode;
    v_new_element xmldom.DOMElement;
    v_new_element_node xmldom.DOMNode;
    v_new_text xmldom.DOMText;
    v_new_text_node xmldom.DOMNode;
    v_employee_id INTEGER;
    v_employer_name hr_organization_units.name%TYPE;
    v_address_line_1 hr_locations.address_line_1%TYPE;
    v_address_line_2 hr_locations.address_line_2%TYPE;
    v_address_line_3 hr_locations.address_line_3%TYPE;
    v_town_or_city hr_locations.town_or_city%TYPE;
    v_region_2 hr_locations.region_2%TYPE;
    v_postal_code hr_locations.postal_code%TYPE;
    v_status INTEGER;
    v_bytes_remaining INTEGER;
    v_current_offset INTEGER;
    v_next_lf_offset INTEGER;
    v_X_offset INTEGER DEFAULT 1;
    v_bytes_to_read INTEGER;
    v_end_of_clob BOOLEAN;
    v_line_number INTEGER;
    v_line VARCHAR2(2000);
    v_bytes_remaining_g_emp INTEGER;
    v_current_offset_g_emp INTEGER;
    v_next_offset_g_emp INTEGER;
    v_bytes_to_read_g_emp INTEGER;
    v_end_of_g_emp BOOLEAN;
    v_amount NUMBER DEFAULT 32000;
    x VARCHAR2(32760);
    v_lf INTEGER;
    e_line_too_long EXCEPTION;
    BEGIN
    DBMS_OUTPUT.PUT_LINE ('Begin process');
    file_handle := utl_file.fopen(dir_name, file_name, 'r');
    IF utl_file.is_open(file_handle) THEN
    DBMS_OUTPUT.PUT_LINE ('File is open');
    END IF;
    BEGIN
    -- Copy w2 xml data file to CLOB
    dbms_lob.createtemporary(w2_data_clob,true,dbms_lob.session);
    DBMS_LOB.OPEN(w2_data_clob, DBMS_LOB.LOB_READWRITE);
    v_clob_length := DBMS_LOB.GETLENGTH(w2_data_clob);
    BEGIN
    LOOP
    utl_file.get_line(file_handle, retrieved_buffer);
    IF NVL(lENGTH(retrieved_buffer),-1) <> -1 THEN
    v_loop_counter := v_loop_counter + 1;
    -- retrieved_buffer := retrieved_buffer || chr(10);
    DBMS_OUTPUT.put_line(v_loop_counter||' '||NVL(LENGTH(RTRIM(retrieved_buffer)),-1)||' ' ||ASCII(SUBSTR(RTRIM(retrieved_buffer),-1,1))||' '||rtrim(retrieved_buffer));
    DBMS_LOB.WRITEAPPEND(w2_data_clob, LENGTH(RTRIM(retrieved_buffer)), RTRIM(retrieved_buffer) );
    ELSE
    DBMS_OUTPUT.put_line('retrieved_buffer IS NULL');
    -- DBMS_LOB.WRITEAPPEND(w2_data_clob, LENGTH(1), ASCII(CHR(13)) );
    END if;
    END LOOP;
    EXCEPTION
    WHEN NO_DATA_FOUND THEN
    DBMS_OUTPUT.PUT_LINE ('last line read: '||retrieved_buffer);
    DBMS_OUTPUT.PUT_LINE ('no more data in loop: '||SQLERRM);
    -- DBMS_LOB.WRITEAPPEN(w2_data_clob, 1,CHR(10));
    -- DBMS_OUTPUT.put_line(chr(13));
    DBMS_LOB.CLOSE(w2_data_clob);
    WHEN OTHERS THEN
    NULL;
    DBMS_OUTPUT.PUT_LINE ('ERROR in loop: '||SQLERRM);
    END;
    v_clob_length := DBMS_LOB.GETLENGTH(w2_data_clob);
    DBMS_OUTPUT.PUT_LINE ('v_clob_length: '||v_clob_length);
    UTL_FILE.FCLOSE (file_handle);
    EXCEPTION
    WHEN OTHERS THEN
    DBMS_OUTPUT.PUT_LINE ('ERROR...'||SQLERRM);
    END;
    DBMS_OUTPUT.PUT_LINE ('last line read: '||retrieved_buffer);
    DBMS_OUTPUT.PUT_LINE ('Number of lines written to CLOB: '|| v_loop_counter);
    v_parser := XMLPARSER.newParser;
    XMLPARSER.setValidationMode(v_parser, FALSE);
    DBMS_OUTPUT.PUT_LINE ('10');
    XMLPARSER.parseClob(v_parser, w2_data_clob);
    DBMS_OUTPUT.PUT_LINE ('20');
    v_document := XMLPARSER.getDocument(v_parser);
    DBMS_OUTPUT.PUT_LINE ('30');
    utl_file.fclose(file_handle);
    DBMS_OUTPUT.PUT_LINE('Process Complete');
    EXCEPTION
    WHEN UTL_FILE.INVALID_PATH
    THEN DBMS_OUTPUT.PUT_LINE ('invalid_path');
    WHEN UTL_FILE.INVALID_MODE
    THEN DBMS_OUTPUT.PUT_LINE ('invalid_mode');
    WHEN UTL_FILE.INVALID_FILEHANDLE
    THEN DBMS_OUTPUT.PUT_LINE ('invalid_filehandle');
    WHEN UTL_FILE.INVALID_OPERATION
    THEN DBMS_OUTPUT.PUT_LINE('invalid_operation');
    WHEN UTL_FILE.READ_ERROR
    THEN DBMS_OUTPUT.PUT_LINE('read_error');
    WHEN UTL_FILE.WRITE_ERROR
    THEN DBMS_OUTPUT.PUT_LINE ('write_error');
    WHEN UTL_FILE.INTERNAL_ERROR
    THEN DBMS_OUTPUT.PUT_LINE ('internal_error');
    WHEN OTHERS
    THEN dbms_output.put_line(SQLERRM);
    END;
    <Version_Number> Version 1.1
    </Version_Number>
    <xapi:requestset xmlns:xapi="http://xmlns.oracle.com/oxp/xapi">
    <xapi:request>
    <xapi:delivery>
    <xapi:filesystem output="/u100/applcsf/dcfap/log/o0285647.tmp" />
    </xapi:delivery>
    <xapi:document output-type="pdf">
    <xapi:template type="pdf" location="${templateName1}">
    <xapi:data>
    <w2>
    <control_number>993536284</control_number>
    <federal_ein>54-1234567</federal_ein>
    <employer_name>Charles D Guf</employer_name>
    <employer_address>Chicken House/Rutherford Crossing FSU
    176 Monket St
    Winchester VA 22603</employer_address>
    <ssn>213-99-9999</ssn>
    <emp_name>Darnell </emp_name>
    <last_name>Simpson</last_name>
    <emp_suffix></emp_suffix>
    <employee_address>3981 Water Lane
    Winchester VA 22602</employee_address>
    <wages_tips_compensation>14299.41</wages_tips_compensation>
    <fit_withheld>464.93</fit_withheld>
    <ss_wages>14949.41</ss_wages>
    <ss_withheld>926.87</ss_withheld>
    <med_wages>14949.41</med_wages>
    <med_withheld>216.75</med_withheld>
    <ss_tips></ss_tips>
    <allocated_tips></allocated_tips>
    <eic_payment></eic_payment>
    <dependent_care></dependent_care>
    <non_qual_plan></non_qual_plan>
    <stat_employee>N</stat_employee>
    <retirement_plan>Y</retirement_plan>
    <sick_pay>N</sick_pay>
    <box14_codea></box14_codea>
    <box14_meaninga></box14_meaninga>
    <box14_codeb></box14_codeb>
    <box14_meaningb></box14_meaningb>
    <box14_codec></box14_codec>
    <box14_meaningc></box14_meaningc>
    <box12_codea>D</box12_codea>
    <box12_meaninga>650</box12_meaninga>
    <box12_codeb></box12_codeb>
    <box12_meaningb></box12_meaningb>
    <box12_codec></box12_codec>
    <box12_meaningc></box12_meaningc>
    <box12_coded></box12_coded>
    <box12_meaningd></box12_meaningd>
    <state1_code>VA</state1_code>
    <state1_ein>30-541252257F-001</state1_ein>
    <state1_wages> 14299.41</state1_wages>
    <state1_tax> 388.49</state1_tax>
    <local1_wages></local1_wages>
    <local1_tax></local1_tax>
    <locality1></locality1>
    <state2_code></state2_code>
    <state2_ein></state2_ein>
    <state2_wages></state2_wages>
    <state2_tax></state2_tax>
    <local2_wages></local2_wages>
    <local2_tax></local2_tax>
    <locality2></locality2>
    <year>2008</year>
    <amended></amended>
    <amended_date></amended_date>
    <print_instruction>N</print_instruction>
    </w2>
    </xapi:data>
    </xapi:template>
    <xapi:template type="pdf" location="${templateName2}">
    <xapi:data />
    </xapi:template>
    </xapi:document>
    </xapi:request>
    </xapi:requestset>

    Well thats the problem - the parser is parsng the clob and is not finding valid XML. It will succeed with
    <Version_Number> Version 1.1
    </Version_Number>
    because, although small its valid XML.
    Im surprised that is the seeded XML from the HRMS team. Have you tried something like SQLDeveloper to look at the contents of the CLOB? Just to ensure your plsql is pulling all of the data out?
    If everything else checks out, I would get an SR logged with Payroll (HRMS) - this is not a BIP issue per se but invalid XML from the HR dev team.
    Regards
    tim

  • Ora-00604 error and ora 01000 error while report generation.

    hi all,
    I am trying to generate the multiple reports of same template through a program.
    While this job is running, i get the following error at the BIP console and the reports don't get generated.
    [101711_044115578][][EXCEPTION] java.sql.SQLException: ORA-00604: error occurred
    at recursive SQL level 1
    ORA-01000: maximum open cursors exceeded
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01000: maximum open cursors exceeded
    ORA-01000: maximum open cursors exceeded
    Kindly help.
    Thanks.

    Lots of resources with a simple search to see what this is about, for example:
    http://www.orafaq.com/wiki/ORA-01000
    ORA-01000:     maximum open cursors exceeded
    Cause:     A host language program attempted to open too many cursors. The initialization parameter OPEN_CURSORS determines the maximum number of cursors per user.
    Action:     Modify the program to use fewer cursors. If this error occurs often, shut down Oracle, increase the value of OPEN_CURSORS, and then restart Oracle.
    open_cursors parameter
    http://download.oracle.com/docs/cd/E11882_01/server.112/e25513/initparams160.htm#REFRN10137
    Oracle support note:
    OERR: ORA-1000 maximum open cursors exceeded (Doc ID 18591.1)

Maybe you are looking for

  • Replacing multiple spaces with a single space

    Hi friends, I have a string. It can have zero/one/multiple spaces. I want to make the multiple spaces to single space. Here are the cases: 1. ' a b c d efg h' should be changed to 'a b c d e f g h' 2. ' a b c d e f g h ' should be changed to 'a b c d

  • Memory leak in Oracle Text under Oracle 8.1.7!!!

    When I wanted to use USER_DATASOTRE preference to use my own formatting tag in Oracle Text, the memory leak occured in Oracle Text! Memory just freed when I close SQL*Plus program My formatting procedure is so easy PROCEDURE format_tag(r IN ROWID, tl

  • JCA DB Adapter pollinginterval in cluster

    Hi All, I have a JCA Adapter to poll DB table every 20 second. The JCA Adapter Invokes OSB proxy. The solution is deployed in weblogic cluster which has 2 nodes. what I noticed is that the polling interval is completely ignored and OSB proxy is invok

  • "Manage Your In App Purchases" link is missing

    hey all, according to every documentation out there, i should be able to see this link .. here is what i did. i created an app in the iTunes Connect. uploaded my binary rejected the review process for the app. and now .. i'm stuck looking around for

  • Data Streams setup: ORA-01374

    Hi, Followed the datastreams document to setup simple replication On Solaris 8 , oracle 9204. While starting the capture process i am getting this error message ORA-01374: log_parallelism greater than 1 not supported in this release Even though my lo