ORA-39065: error unexpected procedure master expdp.

Yesterday, I exported my schematics using the below command

nohup expdp x/x@ORADB DIRECTORY=DATA_PUMP_DIR DUMPFILE=schemabackup_xltcconv_14july2010.dmp logfile=schemabackup_xltcconv_14july2010.log SCHEMAS=CNVOPRO8,CNVOPRO4,CNVREFO3,CNVREFO5,CNVAPPO1,X11DBSECO,CNVAPPO3,CNVREFO4,CNVREFO2,CNVOPRO2,CNVREFO6,CNVAPPO8,CNVAPP1,XDBSECO,CNVAPPO2,CNVPPO6,CNVREFO7,CNVOPRO3,CNVOPRO5,CNVAPPO7,CNVOPRO7,CNVOPRO1,CNVAPPO4,CNVAPPO5,CNVREFO8,CNVREFO1,CNVOPRO6 &

ORA-39065: exception of unexpected master process in KUPC$ QUEUE_INT. PUT_STATUS
ORA-39079: unable to queue message DG, KUPC$ S_1_20100714231902, MCP, 7152, Y
ORA-06512: at "SYS." DBMS_SYS_ERROR', line 86
ORA-06512: at "SYS." ' KUPC$ QUE_INT ', line 969
ORA-23603: enqueue interrupted due to the low GAS STREAMS
ORA-39097: Data Pump job encountered the error unexpected 39079


What could happen?

user9131570 wrote:
Yesterday, I exported my schematics using the below command

nohup expdp x/x@ORADB DIRECTORY=DATA_PUMP_DIR DUMPFILE=schemabackup_xltcconv_14july2010.dmp logfile=schemabackup_xltcconv_14july2010.log SCHEMAS=CNVOPRO8,CNVOPRO4,CNVREFO3,CNVREFO5,CNVAPPO1,X11DBSECO,CNVAPPO3,CNVREFO4,CNVREFO2,CNVOPRO2,CNVREFO6,CNVAPPO8,CNVAPP1,XDBSECO,CNVAPPO2,CNVPPO6,CNVREFO7,CNVOPRO3,CNVOPRO5,CNVAPPO7,CNVOPRO7,CNVOPRO1,CNVAPPO4,CNVAPPO5,CNVREFO8,CNVREFO1,CNVOPRO6 &

ORA-39065: exception of unexpected master process in KUPC$ QUEUE_INT. PUT_STATUS
ORA-39079: unable to queue message DG, KUPC$ S_1_20100714231902, MCP, 7152, Y
ORA-06512: at "SYS." DBMS_SYS_ERROR', line 86
ORA-06512: at "SYS." ' KUPC$ QUE_INT ', line 969
ORA-23603: enqueue interrupted due to the low GAS STREAMS
ORA-39097: Data Pump job encountered the error unexpected 39079

What could happen?

Check metalink note below:
* Expdp fails with ORA-39065, ORA-39078, ORA-23603 [ID 785104.1] *.
His average if you use 10g then increase sga_target else you use 11g memory_target increase also increase the streams_pool_size initialization parameter then try again

Published by: Alex on July 14, 2010 21:27

Tags: Database

Similar Questions

  • ORA-39097: Data Pump job encountered the error unexpected-39076

    Hello world

    Today, I tried to take a pump dump to export my test database (specific table), the version is 10.2.0.4 on Solaris10(64-bit) and I got the following error message

    Work 'SYSTEM '. "" SYS_EXPORT_TABLE_23 "carried out at 09:51:36
    ORA-39097: Data Pump job encountered the error unexpected-39076
    ORA-39065: exception of unexpected master process in KUPV$ FT_INT. DELETE_JOB
    ORA-39076: cannot remove SYS_EXPORT_TABLE_23 work for the SYSTEM user
    ORA-06512: at "SYS." DBMS_SYS_ERROR', line 95
    ORA-06512: at "SYS." "KUPV$ FT_INT", line 934
    ORA-31632: main table "of the SYSTEM. SYS_EXPORT_TABLE_23"not found, invalid or unreachable
    ORA-06512: at "SYS." DBMS_SYS_ERROR', line 95
    ORA-06512: at "SYS." "KUPV$ FT_INT", line 1079
    ORA-20000: failed to send the e-mail message from pl/sql because of:
    ORA-29260: network error: Connect failed because target host or object does not exist
    ORA-39097: Data Pump job encountered the error unexpected-39076
    ORA-39065: exception unexpected master process in HAND
    ORA-39076: cannot remove SYS_EXPORT_TABLE_23 work for the SYSTEM user
    ORA-06512: at "SYS." DBMS_SYS_ERROR', line 95
    ORA-06512: at "SYS." "KUPV$ FT_INT", line 934
    ORA-31632: main table "of the SYSTEM. SYS_EXPORT_TABLE_23"not found, invalid or unreachable
    ORA-06512: at "SYS." DBMS_SYS_ERROR', line 95
    ORA-06512: at "SYS." "KUPV$ FT_INT", line 1079
    ORA-20000: failed to send the e-mail message from pl/sql because of:
    ORA-29260: network error: Connect failed because target host or object does not exist

    I hope that the export dumpfile is valid, but I don't know why I get this error message. One faced this kind of problem. please me tips

    Thank you

    Shan

    Once you see this:

    Work 'SYSTEM '. "" SYS_EXPORT_TABLE_23 "carried out at 09:51:36

    The Data Pump task is done with the dumpfile. It is some clean that is needed and it looks like something in the cleaning failed. Don't know what it was, but you dumpfile should be good. An easy way to test is to run impdp with sqlfile. This will make all import will do, but instead to create objects, he writes the ddl in sql file.

    Impdp directory of the user/password sqlfile = my_test.sql = your_dir dupmfile = your_dump.dmp...

    If it works, then your dumpfile should be fine. The last action of export, it is write the main table Data Pump in the dumpfile. The first thing that import is read this table. So, if you can read it in (which sqlfile impdp) your dump is good.

    Dean

  • EXPDP fails with ORA-39125: worker unexpected fatal error in MAIN $

    Hi friends,

    Oracle 10.2.0.4.0 on Sun OS

    Im trying to metadata_only using EXPDP export

    Faced with the below error

    ORA-39125: worker unexpected fatal worker error of $ MAIN. UNLOAD_METADATA when calling DBMS_METADATA. [FETCH_XML_CLOB]

    ORA-31642: failure of the following SQL statement:

    BEGIN "SYS." "DBMS_RULE_EXP_RULES." SCHEMA_CALLOUT (1,1,1, 10.02.00.04.00 "") END;

    ORA-06512: at "SYS." DBMS_SYS_ERROR', line 86

    ORA-06512: at "SYS." Dbms_metadata", line 907

    ORA-00942: table or view does not exist

    ORA-06512: at "SYS." DBMS_SYS_ERROR', line 95

    ORA-06512: at "SYS." "MAIN $ WORKER", line 6307




    --------------------------------------------------------------------------------
    PL / SQL Call Stack
    --------------------------------------------------------------------------------

    the line object

    serial number of handle

    51bf5dc20 15032 SYS package body. MAIN $ WORKER

    51bf5dc20 6372 SYS package body. MAIN $ WORKER

    51bf5dc20 2396 SYS package body. MAIN $ WORKER

    package body SYS 6944 51bf5dc20. MAIN $ WORKER

    51bf5dc20 1314 SYS package body. MAIN $ WORKER

    51c7e8650 anonymous block 2

    ====================================

    Results:

    I check the status of DBMS_RULE_EXP_RULES

    STATUS OF OWNER OBJECT_TYPE OBJECT_NAME

    --------------------------------------------------------------------------------
    --------------------------------------------------------
    --------------------------------------------------------------------------------

    --------------------------------------------------------------------------------
    DBMS_RULE_EXP_RULES VALID PACKAGE BODY SYS
    SYS DBMS_RULE_EXP_RULES PACKAGE AVAILABLE
    DBMS_RULE_EXP_RULES PUBLIC SYNONYM VALID

    Dbms_metadata & DBMS_SYS_ERROR packages are valid.

    ======================================================

    Error in the alert:

    The value of MAXTRANS parameter ignored (30).
    kupprdp: master the DM00 process started with pid = 25, OS id = 6506
    to run - SYS. KUPM$ MCP. HAND ('SYS_EXPORT_SCHEMA_01', 'SYS', ' KUPC$ C_1_20120908075037', ' KUPC$ S_1_20120908075037', 0);
    kupprdp: work DW01 process began with worker id = 1, pid = 26, OS id = 6633
    to run - SYS. WORKER OF $ MAIN. HAND ('SYS_EXPORT_SCHEMA_01', 'SYS');

    When I check the trace file, find the error below

    ORA-04063: package Ann body. "" COLLECTION "features the errors

    But when I check the condition of the packaging, it is valid.

    Thanks for your help
    KSG

    Salvation;

    ORA-04063: package Ann body. "" COLLECTION "features the errors

    You can try to compile this object? If it gives the error which is error message?

    Respect of
    HELIOS

  • ORA-12012: error on auto work 2160514 and ORA-06576: not a function name or a valid procedure

    I get these errors after updating, could you please review and advise.

    Errors in the /d04/schval/product/10.2.0/admin/SCHVALS1/bdump/schvals1_j000_8224.trc file:

    ORA-12012: error on auto work 2160513

    ORA-06576: not a function or a procedure valid name

    Sun 23 Jun 19:02:55 CDT 2013

    Errors in the /d04/schval/product/10.2.0/admin/SCHVALS1/bdump/schvals1_j001_8463.trc file:

    ORA-12012: error on auto work 2160514

    ORA-06576: not a function or a procedure valid name

    Sun 23 Jun 19:03:53 CDT 2013

    Errors in the /d04/schval/product/10.2.0/admin/SCHVALS1/bdump/schvals1_j001_8463.trc file:

    ORA-12012: error on auto work 2160514

    ORA-06576: not a function or a procedure valid name

    Sun 23 Jun 19:03:53 CDT 2013

    Errors in the /d04/schval/product/10.2.0/admin/SCHVALS1/bdump/schvals1_j001_8463.trc file:

    ORA-12012: error on auto work 2160513

    ORA-06576: not a function or a procedure valid name

    Sun 23 Jun 19:04:53 CDT 2013

    Errors in the /d04/schval/product/10.2.0/admin/SCHVALS1/bdump/schvals1_j001_8463.trc file:

    ORA-12012: error on auto work 2160514

    ORA-06576: not a function or a procedure valid name

    Sun 23 Jun 19:04:53 CDT 2013

    Errors in the /d04/schval/product/10.2.0/admin/SCHVALS1/bdump/schvals1_j001_8463.trc file:

    ORA-12012: error on auto work 2160513

    ORA-06576: not a function or a procedure valid name

    Checked the DB links are working properly

    DB DB link: where I get these errors

    SQL > select count (*) from [email protected] ;

    COUNT (*)

    ----------

    61233

    the ERP DB

    APPS-VAL1 > select count (*) from [email protected] ;

    COUNT (*)

    ----------

    439

    If I try to run it manually, I am getting error below.

    DBMS_SCHEDULER BEGIN. RUN_JOB ("SCHEDULE_REQUEST_DEQUEUE", TRUE); END;

    *

    ERROR on line 1:

    "ORA-27475: ' XXSAP. SCHEDULE_REQUEST_DEQUEUE' must be work

    ORA-06512: at "SYS." DBMS_ISCHED", line 150

    ORA-06512: at "SYS." DBMS_SCHEDULER', line 441

    ORA-06512: at line 1

    SQL > SELECT master, job_name, error # FROM dba_scheduler_job_run_details

    WHERE error # LIKE '% 6576% ';  2

    OWNER

    ------------------------------

    JOB_NAME

    --------------------------------------------------------------------------------

    ERROR #.

    ----------

    SYS

    SCHEDULING_LOCATION_UPDATE

    6576

    SYS

    SCHEDULE_REQUEST_DEQUEUE

    6576

    OWNER

    ------------------------------

    JOB_NAME

    --------------------------------------------------------------------------------

    ERROR #.

    ----------

    SYS

    SCHEDULE_REQUEST_DEQUEUE

    6576

    SQL > select job, what from dba_jobs where broken = 'Y' or chess > 0;

    no selected line

    LOG_DATE                                                                    STATUS                         JOB_NAME

    --------------------------------------------------------------------------- ------------------------------ ----------------------------------------

    23 JUNE 13 11.37.53.128960 AM - 07:00 IS NOT SCHEDULING_NOTIFICATION_UPDATE

    23 JUNE 13 11.37.54.619584 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.38.53.728264 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.39.53.830833 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.40.53.929791 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.41.54.047578 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.42.53.273320 AM - 07:00 IS NOT SCHEDULING_NOTIFICATION_UPDATE

    23 JUNE 13 11.43.53.529692 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.44.53.628774 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.45.53.739038 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.46.53.848009 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    LOG_DATE                                                                    STATUS                         JOB_NAME

    --------------------------------------------------------------------------- ------------------------------ ----------------------------------------

    23 JUNE 13 11.47.57.220078 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    23 JUNE 13 11.48.53.329549 AM - 07:00 IS NOT SCHEDULE_REQUEST_DEQUEUE

    3324 selected lines.

    SQL > 1

    1 * Select log_date, status, JOB_NAME from dba_scheduler_job_run_details where status = 'in FAILURE. "

    Thank you

    Vincent

    I suggest you to move (i.e. rebuild) jobs in the XXSAP scheme rather than use the SYS schema.  In this way, you can run "BEGIN DBMS_SCHEDULER. RUN_JOB' to XXSAP correctly.

    Hemant K Collette

  • ORA-29913: error in executing ODCIEXTTABLEPOPULATE legend while expdp

    Hi all
    My bottom, expdp command fails with the error below:

    With the options of partitioning and Data Mining
    Start "TKSDBO53". "' EXPDP_AR1_TAX_ITEM ': TKSDBO53/***@INTKS10G tables = AR1_TAX_ITEM DUMPFILE=DUMP:Expdp_AR1_TAX_ITEM_%U.dmp LOGFILE = LOG:Expdp_AR1_TAX_ITEM.log CONTENT = DATA_ONLY FILESIZE = 5 G EXCLUDE = INDEX, STATISTICS, CONSTRAINTS, GRANT PARALLEL = JOB_NAME 5 = Expdp_AR1_TAX_ITEM
    Current estimation using BLOCKS method...
    Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
    Total estimation using BLOCKS method: 19,80 MB
    ORA-31693: Data Table object 'TKSDBO53 '. "' AR1_TAX_ITEM ': 'AMAXVALUE_BMAXVALUE' failed to load/unload and being ignored because of the error:
    ORA-29913: error in executing ODCIEXTTABLEPOPULATE legend
    ORA-00001: unique constraint (TKSDBO53. SYS_C00612451) violated
    ORA-06512: at "SYS." "KUPF$ FILE ', line 2580
    ORA-06512: at line 1
    . . exported "TKSDBO53." "' AR1_TAX_ITEM ': 'AMAXVALUE_BMAXVALUE' 324 lines 0 KB
    Table main "TKSDBO53." "' EXPDP_AR1_TAX_ITEM ' properly load/unloaded

    The command I use is
    expdp TKSDBO53/TKSDBO53@INTKS10G tables = AR1_TAX_ITEM DUMPFILE=DUMP:Expdp_AR1_TAX_ITEM_%U.dmp LOGFILE = LOG:Expdp_AR1_TAX_ITEM.log CONTENT = DATA_ONLY FILESIZE = 5 G PARALLEL = JOB_NAME 5 = Expdp_AR1_TAX_ITEM2


    > uname
    Linux

    SQL > select * from v version $;

    BANNER
    ----------------------------------------------------------------
    Oracle Database 10 g Enterprise Edition release 10.2.0.3.0 - 64bi
    PL/SQL version 10.2.0.3.0 - Production
    CORE Production 10.2.0.3.0
    AMT for Linux: release 10.2.0.3.0 - Production
    NLSRTL Version 10.2.0.3.0 - Production

    Please suggest what should I do?

    Regds,
    Malika

    Hmm... Interesting though!

    I think that not some problems that cannot be solved by forum / distance helps. This is one of them. Probably in support of the Oracle if the place where you can solve the problem that why this db rests with ora-29913 while others are not. still the same table structure. If you Gets the support of oracle response, then please post it here (only if it does not violate EULA).

    Or, please wait for the response by other members of the forum.

    Concerning
    Girish Sharma

  • Why I get an ORA-04052 error when I try to compile a procedure?

    Hello
    The following procedure I get an ORA-04052 error when I try to compile the following procedure.
    CREATE OR REPLACE PROCEDURE APPS.Find_String (
     pin_referenced_name IN dba_dependencies.referenced_name%TYPE) 
    
    IS
    
    cursor cur_get_dependancy
    is
    SELECT distinct owner, name, type 
      FROM [email protected]        -- prod.world 
     WHERE lower(referenced_name) = lower(pin_referenced_name) --'ftbv_salesrep_all_1d' 
       AND referenced_type <> 'SYNONYM'
       AND owner <> 'SYS'
     order by name;
     
    v_owner  varchar2(40);
    v_name   varchar2(50);
    v_type   varchar2(40);
     
     
        BEGIN
    
           dbms_output.put_line(upper(pin_referenced_name)||' is found in the following objects.');
           dbms_output.put_line(' ');
           dbms_output.put_line(RPAD('OWNER', 30, ' ')||RPAD('NAME', 60, ' ')||RPAD('OBJECT TYPE', 30, ' '));
           dbms_output.put_line('-------------------------------------------------------------------------------------------------------------------');
    
            FOR i IN cur_get_dependancy
            LOOP
                v_owner := RPAD(i.owner, 30, ' ');
                v_name  := RPAD(i.name, 45, ' ');
                v_type  := RPAD(i.type, 30, ' ');
                
               
                dbms_output.put_line(v_owner ||v_name|| v_type);
    
            END LOOP;
    
    END find_string;
    I use the [email protected] link. Commented compiles it procedure for other links of database used in the cursor, including the one to the right of the code 'prod.world '.

    What is even more strange is that I took the SELECT statement
    SELECT distinct owner, name, type 
      FROM [email protected]        -- prod.world 
     WHERE lower(referenced_name) = lower(pin_referenced_name) --'ftbv_salesrep_all_1d' 
       AND referenced_type <> 'SYNONYM'
       AND owner <> 'SYS'
     order by name;
    the procedure and he ran on the command line by using the link to @pinp.world, the SQL statement is fine. But when I tried to compile the procedure above to this exact same SQL query with the same exact link I get the following string of errors.
    ORA-04052: error occurred when looking up remote object [email protected]
    ORA-00604: error occurred at recursive SQL level 1
    ORA-02068: following severe error from PINP
    ORA-03113: end-of-file on communication channel
    How the link can work very well in a regular SQL but then cause an error when its code compiled in that otherwise compile correctly when you use any link, or even just a simple database. Does anyone have any suggestions?

    Hello

    Good thounght, but no, there is no privilege SELECT ANY VIEW; SELECT ANY TABLE includes views and materilaized.

    I suspect that the problem is something specific to the data dictionary. I have just connected as SYS and granted SELECT ANY TABLE to another user with minimum privileges, X. X, ALL_VIEWS included so all views dba_, including the dba_dependencies. However, X was still unable to dba_dependencies the query either in SQL * more or PL/SQL.

  • ORA-39126: worker unexpected fatal error

    Hello
    When an export file is imported full by following the command line:

    Impdp system/***@orcl DUMPFILE is EXP_FUL_H9DEV. LOGFILE = MYLOG.log DMP

    I received:

    ORA-39126: worker unexpected fatal worker error of $ MAIN. PUT_DDL [VIEW: "H9DEV".] ["" PS_AEAPPL_VW "]
    ORA-44001: invalid schema

    ORA-06512: at "SYS." DBMS_SYS_ERROR', line 95
    ORA-06512: at "SYS." "MAIN$ WORKER", line 6273

    Any idea?

    Thanks for help.

    [SEE: "H9DEV".] ["" PS_AEAPPL_VW "]

    A guess: this view query objects of other schemes, which do not exist in the new database or on what H9DEV does not have appropriate privileges?

    If not, is there more information in the newspaper?

    Cheers, APC

    blog: http://radiofreetooting.blogspot.com

  • ORA-02354: Error exporting/importing data, ORA-01555: snapshot too old: rollback segment number with the name "" too small

    Hello

    I am getting below error while taking expdp backup table of BLOB.

    ORA-31693: Data Table object 'HCLM_ADMIN '. "' SCAN_UPLOADEDFILES_TEMP ' failed to load/unload and being ignored because of the error:

    ORA-02354: Error exporting/importing data

    ORA-01555: snapshot too old: rollback segment number with the name "" too small

    ORA-22924: snapshot too old

    ORA-31693: Data Table object 'HCLM_ADMIN '. "' TPA_FAXWATCHER ' failed to load/unload and being ignored because of the error:

    ORA-02354: Error exporting/importing data

    ORA-01555: snapshot too old: rollback segment number with the name "" too small

    ORA-22924: snapshot too old

    We have already set aside retention to 50000 .table structure are:

    SQL > show Cancel parameter

    VALUE OF TYPE NAME

    ------------------------------------ ----------- ------------------------------

    UNDO_MANAGEMENT string AUTO

    UNDO_RETENTION integer 50000

    undo_tablespace string UNDOTBS1

    SQL > alter table hclm_admin. SCAN_UPLOADEDFILES_TEMP modify lob (FILE_BLOB) (RETENTION);

    Modified table.

    SQL > select nom_de_colonne, pctversion and retention

    from dba_lobs where owner = 'HCLM_ADMIN' and table_name = "SCAN_UPLOADEDFILES_TEMP";

    COLUMN_NAME

    --------------------------------------------------------------------------------

    PCTVERSION RETENTION

    ---------- ----------

    FILE_BLOB

    50000

    SQL > alter table hclm_admin. TPA_FAXWATCHER modify lob (FILEDATA_BLOB) (RETENTION);

    Modified table.

    SQL > select column_name, pctversion and retention of dba_lobs where owner = 'HCLM_ADMIN' and table_name = "SCAN_UPLOADEDFILES_TEMP";

    Column_name PCTVERSION RETENTION

    ---------- ----------

    FILE_BLOB

    50000

    CREATE TABLE HCLM_ADMIN. TPA_FAXWATCHER

    (

    FILENAME_VAR VARCHAR2 (50 BYTE),

    DATE OF CREATED_DATE_DTE,

    FILEPATH_VAR VARCHAR2 (100 BYTE),

    DATE OF TIMESTAMP_DTE,

    FAXNO_VAR VARCHAR2 (15 BYTE),

    DEPARTMENT_VAR VARCHAR2 (50 BYTE),

    REQUESTTYPE_VAR VARCHAR2 (50 BYTE),

    TAGTO_VAR VARCHAR2 (50 BYTE),

    REMARK_VAR VARCHAR2 (1000 BYTE),

    DOCTYPE_VAR VARCHAR2 (50 BYTE),

    TAGTOVALUE_VAR VARCHAR2 (50 BYTE),

    DOCTYPE_OTHER_VAR VARCHAR2 (50 BYTE),

    HEGIC_NO_VAR VARCHAR2 (50 BYTE),

    RECORDNO_NUM NUMBER OF NON-NULL,

    FILEDATA_BLOB BLOB,

    DATE OF FAXLOCKDATE_DTE,

    NUMBER OF FAXLOCKSTATUS_VAR

    FAXLOCKBYUSER_VAR VARCHAR2 (50 BYTE)

    )

    (STORE AS) LOB (FILEDATA_BLOB)

    TABLESPACE HCLM_ALERTSVC

    ALLOW ONLINE STORAGE

    8192 CHUNK

    RETENTION

    NOCACHE

    LOGGING

    INDEX)

    TABLESPACE HCLM_ALERTSVC

    STORAGE)

    64K INITIALS

    ACCORDING TO 1 M

    MINEXTENTS 1

    MAXEXTENTS UNLIMITED

    PCTINCREASE 0

    DEFAULT USER_TABLES

    ))

    STORAGE)

    64K INITIALS

    ACCORDING TO 1 M

    MINEXTENTS 1

    MAXEXTENTS UNLIMITED

    PCTINCREASE 0

    DEFAULT USER_TABLES

    ))

    TABLESPACE HCLM_ALERTSVC

    PCTUSED 0

    PCTFREE 10

    INITRANS 1

    MAXTRANS 255

    STORAGE)

    64K INITIALS

    ACCORDING TO 1 M

    MINEXTENTS 1

    MAXEXTENTS UNLIMITED

    PCTINCREASE 0

    DEFAULT USER_TABLES

    )

    LOGGING

    NOCOMPRESS

    NOCACHE

    NOPARALLEL

    MONITORING;

    ALTER TABLE HCLM_ADMIN. (ADD) TPA_FAXWATCHER

    KEY ELEMENTARY SCHOOL

    (RECORDNO_NUM)

    USING INDEX

    TABLESPACE HCLM_ALERTSVC

    PCTFREE 10

    INITRANS 2

    MAXTRANS 255

    STORAGE)

    64K INITIALS

    ACCORDING TO 1 M

    MINEXTENTS 1

    MAXEXTENTS UNLIMITED

    PCTINCREASE 0

    ));

    CREATE TABLE HCLM_ADMIN. SCAN_UPLOADEDFILES_TEMP

    (

    NUMBER OF TEMPID_NUM

    SESSION_ID VARCHAR2 (200 BYTE),

    NUMBER OF UPLOADFILE_NUM

    NUMBER OF DOCNO_NUM

    NUMBER OF SCANJOB_NUM

    FILENAME_VAR VARCHAR2 (200 BYTE),

    FILETYPE_VAR VARCHAR2 (200 BYTE),

    FILE_BLOB BLOB,

    VARCHAR2 (200 BYTE) FLAG,

    NUMBER OF USERID_NUM

    CREATED_DATE DATE

    )

    (STORE AS) LOB (FILE_BLOB)

    TABLESPACE PHCLMDBTBS

    ALLOW ONLINE STORAGE

    8192 CHUNK

    RETENTION

    NOCACHE

    LOGGING

    INDEX)

    TABLESPACE PHCLMDBTBS

    STORAGE)

    64K INITIALS

    ACCORDING TO 1 M

    MINEXTENTS 1

    MAXEXTENTS UNLIMITED

    PCTINCREASE 0

    DEFAULT USER_TABLES

    ))

    STORAGE)

    64K INITIALS

    ACCORDING TO 1 M

    MINEXTENTS 1

    MAXEXTENTS UNLIMITED

    PCTINCREASE 0

    DEFAULT USER_TABLES

    ))

    TABLESPACE PHCLMDBTBS

    PCTUSED 0

    PCTFREE 10

    INITRANS 1

    MAXTRANS 255

    STORAGE)

    64K INITIALS

    ACCORDING TO 1 M

    MINEXTENTS 1

    MAXEXTENTS UNLIMITED

    PCTINCREASE 0

    DEFAULT USER_TABLES

    )

    LOGGING

    NOCOMPRESS

    NOCACHE

    NOPARALLEL

    MONITORING;

    Kind regards

    Hello

    First check the lob corrupt as:

    SQL > create table corrupted_lob_data (corrupted_rowid rowid);

    Table created.

    SQL > set off concat

    SQL >

    declare

    SQL > error_1555 exception;

    pragma exception_init (error_1555,-1555);

    number num.

    Start

    for cursor_lob in (select rowid r, & lob_column of table_owner. & table_with_lob) loop

    Start

    NUM: = dbms_lob.instr (. cursor_lob & lob_column, hextoraw ('889911'));

    exception

    When error_1555 then

    insert into corrupted_lob_data values (cursor_lob.r);

    commit;

    end;

    end loop;

    end;

    2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

    17.

    Enter the value of lob_column: FILE_BLOB

    Enter the table_owner value: hclm_admin

    Enter the value of table_with_lob: SCAN_UPLOADEDFILES_TEMP

    former 6: for cursor_lob in (select rowid r, & lob_column of table_owner. & table_with_lob) loop

    6 news: for cursor_lob (select rowid r, FILE_BLOB of hclm_admin loop SCAN_UPLOADEDFILES_TEMP.)

    old 8: num: = dbms_lob.instr (. cursor_lob & lob_column, hextoraw ('889911'));

    8 new: num: = dbms_lob.instr (cursor_lob. FILE_BLOB, hextoraw ('889911'));

    PL/SQL procedure successfully completed.

    SQL > select * from corrupted_lob_data;

    CORRUPTED_ROWID

    ------------------

    AAASF/AAKAABacyAAA

    To resolve this problem, we have 3 options

    (1) to restore and recover the LOB segment using physical backup.

    (2) empty LOBs affected using the UPDATE, as mentioned in the Note 787004.1statement:

    SQL > update SCAN_UPLOADEDFILES_TEMP

    Set FILE_BLOB = empty_blob()

    where rowid in (select corrupted_rowid

    of corrupted_lob_data);

    SQL > commit;

    (3) perform the export, excluding the corrupt ROWID. by adding the following to export command parameter

    Query =------"where rowid not in (\'AAASF/AAKAABacyAAA\'\) \ \" "

    Kind regards

    Alok Dwivedi

  • ORA-29285: error writing file

    Hi, I'm trying to clear a table in a flat file, & provided the stored procedure using my Tom Kyte @ https://asktom.oracle.com/pls/asktom/f?p=100:11:0:NO:P11_QUESTION_ID:88212348059.

    It worked well at first, but now I always get the following error message:

    ERROR on line 1:

    ORA-29285: error writing file

    ORA-06512: at "OFSA_ATOMIC. DUMP_TAB_TO_CSV", line 45

    ORA-06512: at line 1

    The search for this error ORA out Virgin on MOS.

    Any ideas how to solve this problem?

    I already checked for space on the file system and there is lots of space available.

    Also, the file is created with a size of 0 bytes before the procedure was abandoned.

    Thank you

    -CV

    Hello

    trying to figure out what has changed since it worked. Length of the line would be greater than 1024 default that uses Tom proc?

    http://docs.Oracle.com/CD/E11882_01/AppDev.112/e40758/u_file.htm#ARPLS70900

    The FOPEN max_linesize parameter must be a number in the range 1 to 32 767. If not specified, Oracle provides a default value of 1024.

  • ORA-29913: error in executing ODCIEXTTABLEFETCH legend

    Hello

    I get an error when you run queries against a view.
    SQL > select count (*) in the TOOL_ADMIN. DATABASE_STATS;.

    ERROR on line 1:
    ORA-29913: error in executing ODCIEXTTABLEFETCH legend
    ORA-30653: reject limit reached
    ORA-06512: at "SYS." ORACLE_LOADER', line 52

    SQL > select MASTER, object_name, object_type, status, CREATED from object where object_name like UPPER ('Database_Stats');

    OWNER OBJECT_NAME OBJECT_TYPE STATUS CREATED
    ------------------------------ ------------------------------ ------------------- ------- ---------
    TOOL_ADMIN DATABASE_STATS VIEW VALID MARCH 9, 10


    Could you please share your experiences on this subject?

    Kind regards
    VN

    Based on the view of the error messages. TOOL_ADMIN done DATABASE_STATS refers to an external table. This means that whenever you select in the view that oracle bed associated with external table file is loading based on the external table definition. And this time the number of records in the file not following the external table definition exceeds the limit of rejection of external table. Check the definition of the view. Determinte log, bad and throw the files and examine them to see records or reasons were rejected.

    SY.

  • InPlace schema evolution error: ORA-31166: error code internal etc...

    Hello

    I have a table in which I will be storing an XMLTYPE column based on an XML schema. I use the following version of the database:
    SQL*Plus: Release 11.2.0.1.0 Production on Thu Aug 23 18:20:12 2012
    
    Copyright (c) 1982, 2010, Oracle.  All rights reserved.
    
    
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    Now, when I run my test InPlace Schema Evolution, I get the following error message:

    < font color = "red" >
    ORA-31166: internal error code to handle ignorable attributes
    < / make >

    I built a re-producable case of test for the purpose of this post on the forum. For starters, I have a database scheme grants the following privileges:
    DIRECTLY GRANTED SYSTEM PRIVS
    =============================
    CREATE TRIGGER
    ALTER SESSION
    CREATE TABLE
    
    EXECUTE PRIVS (SYS-OWNED PACKAGES)
    =============
    EXECUTE ON DBMS_XMLSCHEMA
    
    ROLES GRANTED
    =============
    CONNECT
    DATA_ROLE
    
    DATA_ROLE DDL
    =============
    create role DATA_ROLE not identified;
    grant create database link to DATA_ROLE;
    GRANT CREATE MATERIALIZED VIEW TO DATA_ROLE;
    grant create procedure to DATA_ROLE;
    grant create sequence to DATA_ROLE;
    GRANT CREATE SYNONYM TO DATA_ROLE;
    grant create table to DATA_ROLE with admin option;
    grant create trigger to DATA_ROLE;
    grant create view to DATA_ROLE;
    grant select any dictionary to DATA_ROLE;
    All other scripts are run as the database schema. For the purposes of clarity, let's call the {*} TEST_DB_SCHEMA {*}. I follow the steps below in this scheme:

    H3. 1. run this PL/SQL script to record the Version 1 of my XML schema:
    PROMPT -------------------------------;
    PROMPT INITIAL XML SCHEMA REGISTRATION;
    PROMPT -------------------------------;
    
    SET SERVEROUTPUT ON
    SET FEEDBACK OFF
    
    DECLARE
       l_xsd_url_con CONSTANT VARCHAR2(60) := 'http://home/xsd/test_binXML_v1.xsd';
       
       l_xml_schema VARCHAR2(32767);
       
       E_XSD_ALREADY_REGISTERED EXCEPTION;
       PRAGMA EXCEPTION_INIT(E_XSD_ALREADY_REGISTERED, -31085);
    BEGIN
       l_xml_schema :=
          '<xs:schema'||CHR(10)||
          'xmlns:xs="http://www.w3.org/2001/XMLSchema"'||CHR(10)||
          'xmlns:xdb="http://xmlns.oracle.com/xdb"'||CHR(10)||
          'version="1.0"'||CHR(10)||
          'xdb:storeVarrayAsTable = "true">'||CHR(10)||
          ' <xs:element name="TransactionBatch" type="TransactionBatchType" xdb:defaultTable="XSD_TEST_BATCH_BINXML1"/>'||CHR(10)||
          ' <xs:complexType name="TransactionBatchType">'||CHR(10)||
          '  <xs:sequence>'||CHR(10)||
          '   <xs:element name="Transaction" type="TransactionType" minOccurs="1" maxOccurs="unbounded" xdb:defaultTable="XSD_TEST_TRANSACTION_BINXML1"/>'||CHR(10)||
          '  </xs:sequence>'||CHR(10)||
          ' </xs:complexType>'||CHR(10)||
          ' <xs:complexType name="TransactionType">'||CHR(10)||
          '  <xs:sequence>'||CHR(10)||
          '   <xs:element name="Portal" type="PortalType" minOccurs="1" maxOccurs="1" />'||CHR(10)||
          '   <xs:element name="CustomerId" type="CustomerIdType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '   <xs:element name="TransactionQuantity" type="TransactionQuantityType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '   <xs:element name="AppTransactionId" type="AppTransactionIdType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '   <xs:element name="TransactionDetails" type="TransactionDetailType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '   <xs:element name="Username" type="UsernameType" minOccurs="1" maxOccurs="1" />'||CHR(10)||
          '  </xs:sequence>'||CHR(10)||
          ' </xs:complexType>'||CHR(10)||
          ' <xs:simpleType name="PortalType">'||CHR(10)||
          '  <xs:restriction base="xs:string">'||CHR(10)||
          '   <xs:minLength value="1"/>'||CHR(10)||
          '   <xs:maxLength value="30"/>'||CHR(10)||
          '   <xs:enumeration value="TEST1"/>'||CHR(10)||
          '   <xs:enumeration value="TEST2"/>'||CHR(10)||
          '  </xs:restriction>'||CHR(10)||
          ' </xs:simpleType>'||CHR(10)||
          ' <xs:simpleType name="CustomerIdType">'||CHR(10)||
          '  <xs:restriction base="xs:string"/>'||CHR(10)||
          ' </xs:simpleType>'||CHR(10)||
          ' <xs:simpleType name="TransactionQuantityType">'||CHR(10)||
          '  <xs:restriction base="xs:integer">'||CHR(10)||
          '   <xs:minExclusive value="0"/>'||CHR(10)||
          '  </xs:restriction>'||CHR(10)||
          ' </xs:simpleType>'||CHR(10)||
          ' <xs:simpleType name="AppTransactionIdType">'||CHR(10)||
          '  <xs:restriction base="xs:string">'||CHR(10)||
          '   <xs:minLength value="1"/>'||CHR(10)||
          '   <xs:maxLength value="20"/>'||CHR(10)||
          '  </xs:restriction>'||CHR(10)||
          ' </xs:simpleType>'||CHR(10)||
          ' <xs:simpleType name="TransactionDetailType">'||CHR(10)||
          '  <xs:restriction base="xs:string">'||CHR(10)||
          '   <xs:minLength value="1"/>'||CHR(10)||
          '  </xs:restriction>'||CHR(10)||
          ' </xs:simpleType>'||CHR(10)||
          ' <xs:simpleType name="UsernameType">'||CHR(10)||
          '  <xs:restriction base="xs:string">'||CHR(10)||
          '   <xs:minLength value="1"/>'||CHR(10)||
          '   <xs:maxLength value="30"/>'||CHR(10)||
          '  </xs:restriction>'||CHR(10)||
          ' </xs:simpleType>'||CHR(10)||
          '</xs:schema>';
       
       DBMS_XMLSCHEMA.REGISTERSCHEMA(
          schemaurl       => l_xsd_url_con,
          schemadoc       => l_xml_schema,
          local           => TRUE,                             -- XSD must only be visible to the Owner DB Schema in which this script is run.
          genTypes        => FALSE,                            -- Don't want to generate object types, as we're using Binary XML.
          force           => FALSE,                            -- Raise all errors on creation
          owner           => USER,                             -- XML Schema will belong to the currently executing user.
          options         => DBMS_XMLSCHEMA.REGISTER_BINARYXML -- We wish to register the XSD as Binary XML.
       );
       
    EXCEPTION
       WHEN E_XSD_ALREADY_REGISTERED
       THEN
          DBMS_OUTPUT.PUT_LINE('XML Schema '||l_xsd_url_con||' is already registered.');
          
    END;
    /
    
    SET FEEDBACK ON
    H3. 2. create a bunch of Table with an XMLTYPE column based on version 1 of my XML schema:
    PROMPT ----------------------;
    PROMPT ONE-OFF DDL STATEMENTS;
    PROMPT ----------------------;
    
    DROP TABLE test_batch;
    DROP SEQUENCE seq_test_batch_id;
    
    CREATE TABLE test_batch
    (
       batch_id        NUMBER(20),
       batch_timestamp TIMESTAMP   DEFAULT SYSTIMESTAMP,
       batch_xml       XMLTYPE,
       CONSTRAINT tbh_batch_id_nn        CHECK(batch_id IS NOT NULL),
       CONSTRAINT tbh_batch_timestamp_nn CHECK(batch_timestamp IS NOT NULL),
       CONSTRAINT tbh_batch_xml_nn       CHECK(batch_xml IS NOT NULL)
    )
    XMLTYPE COLUMN batch_xml STORE AS SECUREFILE BINARY XML
    XMLSCHEMA "http://home/xsd/test_binXML_v1.xsd"
    ELEMENT "TransactionBatch"
    PARTITION BY RANGE(batch_timestamp)
    INTERVAL (NUMTOYMINTERVAL(1, 'MONTH'))
    (
       PARTITION P_TEST_BATCH_201208 VALUES LESS THAN (TO_DATE('01-SEP-2012', 'DD-MON-YYYY')) TABLESPACE &&TABLSPACE_OF_YOUR_CHOICE
    );
    
    CREATE UNIQUE INDEX idx_tbh_batch_id ON test_batch(batch_id)
    TABLESPACE TXTREME_IDX_XLG;
    
    ALTER TABLE test_batch
       ADD CONSTRAINT tbh_batch_id_pk PRIMARY KEY (batch_id) USING INDEX idx_tbh_batch_id;
    
    CREATE SEQUENCE seq_test_batch_id
    START WITH 1
    INCREMENT BY 1
    MAXVALUE 99999999999999999999
    CYCLE
    NOCACHE
    NOORDER;
    H3. 3. fill this table with the test data.
    PROMPT --------------------------;
    PROMPT CREATING INITIAL TEST DATA;
    PROMPT --------------------------;
    
    TRUNCATE TABLE TEST_BATCH;
    
    SET TIMING ON
    DECLARE
       l_batch_count_con CONSTANT NUMBER(4) := 200;
       
       l_transaction_count   PLS_INTEGER;
       l_total_transactions  PLS_INTEGER DEFAULT 0;
       l_transaction_xmlclob CLOB;
       l_transaction_xmldoc  XMLTYPE;
    BEGIN
       FOR idx IN 1..l_batch_count_con
       LOOP
          l_transaction_count := TRUNC(DBMS_RANDOM.VALUE(1,100));
          
          -- Initialise XML CLOB String. 
          l_transaction_xmlclob := '<?xml version="1.0"?>'||CHR(10)||'<TransactionBatch>';
          
          -- Insert the contents of the XML CLOB String.
          FOR idx IN 1 .. l_transaction_count
          LOOP
             l_transaction_xmlclob := l_transaction_xmlclob||CHR(10)||
                                      '  <Transaction>'||CHR(10)||
                                      '    <Portal>TEST1</Portal>'||CHR(10)||
                                      '    <CustomerId>1234567891</CustomerId>'||CHR(10)||
                                      '    <TransactionQuantity>4</TransactionQuantity>'||CHR(10)||
                                      '    <AppTransactionId>1232K89C</AppTransactionId>'||CHR(10)||
                                      '    <TransactionDetails>This is another long free text field</TransactionDetails>'||
                                      '    <Username>Jimbo2</Username>'||CHR(10)||
                                      '  </Transaction>';
          END LOOP;
          
          --Terminate XML CLOB String.
          l_transaction_xmlclob := l_transaction_xmlclob||CHR(10)||'</TransactionBatch>';
          
          -- Create XMLTYPE XML Document.
          l_transaction_xmldoc := XMLTYPE.createXML(l_transaction_xmlclob);
          
          -- Populate the TEST_BATCH Table.
          INSERT INTO test_batch
            ( batch_id,
              batch_timestamp,
              batch_xml
            )
          VALUES
            ( SEQ_TEST_BATCH_ID.NEXTVAL,
              SYSTIMESTAMP,
              l_transaction_xmldoc
            );
            
          l_total_transactions := l_total_transactions + l_transaction_count;
       END LOOP;
       
       DBMS_OUTPUT.PUT_LINE('Inserted a total of '||l_total_transactions||' transaction XML pieces across '||l_batch_count_con||' Test Batches.');
       COMMIT;
       DBMS_OUTPUT.PUT_LINE('Commit complete.');
    END;
    /
    
    SET TIMING OFF
    H3. 4. save the Version 2 of my XML schema
    PROMPT -----------------------------------------------------------------------------------;
    PROMPT NEW XML SCHEMA REGISTRATION - IDENTICAL TO OLD SCHEMA EXCEPT FOR NEW <Test> ELEMENT;
    PROMPT -----------------------------------------------------------------------------------;
    
    SET FEEDBACK OFF
    
    DECLARE
       l_xsd_url_con CONSTANT VARCHAR2(60) := 'http://home/xsd/test_binXML_v2.xsd';
       
       l_xml_schema VARCHAR2(32767);
       
       E_XSD_ALREADY_REGISTERED EXCEPTION;
       PRAGMA EXCEPTION_INIT(E_XSD_ALREADY_REGISTERED, -31085);
    BEGIN
       l_xml_schema :=
          '<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns.oracle.com/xdb" version="1.0" xdb:storeVarrayAsTable="true">'||CHR(10)||
          '<xs:element name="TransactionBatch" type="TransactionBatchType" xdb:defaultTable="XSD_TEST_BATCH_BINXML2"/>'||CHR(10)||
          '<xs:complexType name="TransactionBatchType">'||CHR(10)||
          ' <xs:sequence>'||CHR(10)||
          '  <xs:element name="Transaction" type="TransactionType" minOccurs="1" maxOccurs="unbounded" xdb:defaultTable="XSD_TEST_TRANSACTION_BINXML2"/>'||CHR(10)||
          ' </xs:sequence>'||CHR(10)||
          '</xs:complexType>'||CHR(10)||
          '<xs:complexType name="TransactionType">'||CHR(10)||
          ' <xs:sequence>'||CHR(10)||
          '  <xs:element name="Portal" type="PortalType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '  <xs:element name="CustomerId" type="CustomerIdType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '  <xs:element name="TransactionQuantity" type="TransactionQuantityType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '  <xs:element name="AppTransactionId" type="AppTransactionIdType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '  <xs:element name="TransactionDetails" type="TransactionDetailType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '  <xs:element name="Username" type="UsernameType" minOccurs="1" maxOccurs="1"/>'||CHR(10)||
          '  <xs:element name="Test" type="TestType" minOccurs="0" maxOccurs="1"/>'||CHR(10)||
          ' </xs:sequence>'||CHR(10)||
          '</xs:complexType>'||CHR(10)||
          '<xs:simpleType name="PortalType">'||CHR(10)||
          ' <xs:restriction base="xs:string">'||CHR(10)||
          '  <xs:minLength value="1"/>'||CHR(10)||
          '  <xs:maxLength value="30"/>'||CHR(10)||
          '  <xs:enumeration value="TEST1"/>'||CHR(10)||
          '  <xs:enumeration value="TEST2"/>'||CHR(10)||
          ' </xs:restriction>'||CHR(10)||
          '</xs:simpleType>'||CHR(10)||
          '<xs:simpleType name="CustomerIdType">'||CHR(10)||
          ' <xs:restriction base="xs:string"/>'||CHR(10)||
          '</xs:simpleType>'||CHR(10)||
          '<xs:simpleType name="TransactionQuantityType">'||CHR(10)||
          ' <xs:restriction base="xs:integer">'||CHR(10)||
          '  <xs:minExclusive value="0"/>'||CHR(10)||
          ' </xs:restriction>'||CHR(10)||
          '</xs:simpleType>'||CHR(10)||
          '<xs:simpleType name="AppTransactionIdType">'||CHR(10)||
          ' <xs:restriction base="xs:string">'||CHR(10)||
          '  <xs:minLength value="1"/>'||CHR(10)||
          '  <xs:maxLength value="20"/>'||CHR(10)||
          ' </xs:restriction>'||CHR(10)||
          '</xs:simpleType>'||CHR(10)||
          '<xs:simpleType name="TransactionDetailType">'||CHR(10)||
          ' <xs:restriction base="xs:string">'||CHR(10)||
          '  <xs:minLength value="1"/>'||CHR(10)||
          ' </xs:restriction>'||CHR(10)||
          '</xs:simpleType>'||CHR(10)||
          '<xs:simpleType name="UsernameType">'||CHR(10)||
          ' <xs:restriction base="xs:string">'||CHR(10)||
          '  <xs:minLength value="1"/>'||CHR(10)||
          '  <xs:maxLength value="30"/>'||CHR(10)||
          ' </xs:restriction>'||CHR(10)||
          '</xs:simpleType>'||CHR(10)||
          '<xs:simpleType name="TestType">'||CHR(10)||
          ' <xs:restriction base="xs:string">'||CHR(10)||
          '  <xs:minLength value="1"/>'||CHR(10)||
          '  <xs:maxLength value="30"/>'||CHR(10)||
          ' </xs:restriction>'||CHR(10)||
          '</xs:simpleType>'||CHR(10)||
          '</xs:schema>';
       
       DBMS_XMLSCHEMA.REGISTERSCHEMA(
          schemaurl       => l_xsd_url_con,
          schemadoc       => l_xml_schema,
          local           => TRUE,                             -- XSD must only be visible to the Owner DB Schema in which this script is run.
          genTypes        => FALSE,                            -- Don't want to generate object types, as we're using Binary XML.
          force           => FALSE,                            -- Raise all errors on creation
          owner           => USER,                             -- XML Schema will belong to the currently executing user.
          options         => DBMS_XMLSCHEMA.REGISTER_BINARYXML -- We wish to register the XSD as Binary XML.
       );
       
    EXCEPTION
       WHEN E_XSD_ALREADY_REGISTERED
       THEN
          DBMS_OUTPUT.PUT_LINE('XML Schema '||l_xsd_url_con||' is already registered.');
          
    END;
    /
    
    SET FEEDBACK ON
    H3. 5 test to insert a new XML document in line with the second XML schema. This test fails as expected.
    PROMPT ---------------------------------------------------------------;
    PROMPT ATTEMPT TO INSERT V2 XSD-COMPLIANT XMLDOC INTO TEST_BATCH TABLE;
    PROMPT ---------------------------------------------------------------;
    
    DECLARE
       l_transaction_xmldoc XMLTYPE;
       
       E_XSD_VALIDATION_FAILURE EXCEPTION;
       PRAGMA EXCEPTION_INIT(E_XSD_VALIDATION_FAILURE, -31061);
    BEGIN
       l_transaction_xmldoc := XMLTYPE.createXML(
                                  '<?xml version="1.0" encoding="UTF-8"?>'||CHR(10)||
                                  '<TransactionBatch>'||CHR(10)||
                                  '  <Transaction>'||CHR(10)||
                                  '    <Portal>CARMAN</Portal>'||CHR(10)||
                                  '    <CustomerId>1234567891</CustomerId>'||CHR(10)||
                                  '    <TransactionQuantity>4</TransactionQuantity>'||CHR(10)||
                                  '    <AppTransactionId>1232K89C</AppTransactionId>'||CHR(10)||
                                  '    <TransactionDetails>This is a long free text field</TransactionDetails>'||CHR(10)||
                                  '    <Username>Jimbo2</Username>'||CHR(10)||
                                  '    <Test>This is an In-Place Schema Evolution Test</Test>'||CHR(10)||
                                  '  </Transaction>'||CHR(10)||
                                  '</TransactionBatch>'
                               );
       
       -- Attempt to populate the SUBMISSION_BATCH Table.
       INSERT INTO submission_batch
         ( batch_id,
           batch_timestamp,
           batch_xml
         )
       VALUES
         ( SEQ_SUB_BATCH_ID.NEXTVAL,
           SYSTIMESTAMP,
           l_transaction_xmldoc
         );
       
       DBMS_OUTPUT.PUT_LINE(SQL%ROWCOUNT||' row inserted.');
       COMMIT;
       DBMS_OUTPUT.PUT_LINE('Commit complete.');
    
    EXCEPTION
       WHEN E_XSD_VALIDATION_FAILURE
       THEN
          DBMS_OUTPUT.PUT_LINE('Insert failed as expected.'||CHR(10));
          DBMS_OUTPUT.PUT_LINE(SQLERRM);
    END;
    /
    H3. 6. try Inplace development of Version 1 of the XML schema in Version 2.
    PROMPT --------------------------------------------------------------------------------------;
    PROMPT PERFORM IN-PLACE EVOLUTION AND DE-REGISTER/PURGE OLD SCHEMA IF EVOLUTION IS SUCCESSFUL;
    PROMPT --------------------------------------------------------------------------------------;
    
    SET TIMING ON
    
    DECLARE
       l_current_schema   XMLTYPE;
       l_new_schema       XMLTYPE;
       l_xsd_differences  XMLTYPE;
       
       l_resource         BOOLEAN;
    BEGIN
       SELECT schema
         INTO l_current_schema
         FROM user_xml_schemas
        WHERE schema_url = 'http://home/xsd/test_binXML_v1.xsd';
       
       SELECT schema
         INTO l_new_schema
         FROM user_xml_schemas
        WHERE schema_url = 'http://home/xsd/test_binXML_v2.xsd';
       
       SELECT XMLDIFF(l_current_schema, l_new_schema)
         INTO l_xsd_differences
         FROM dual;
       
       DBMS_OUTPUT.PUT_LINE('Successfully extrapolated XDIFF XML Document.');
       
       DBMS_XMLSCHEMA.inPlaceEvolve( 'http://home/xsd/test_binXML_v1.xsd',
                                     l_xsd_differences,
                                     DBMS_XMLSCHEMA.INPLACE_TRACE
                                   );
       
       DBMS_OUTPUT.PUT_LINE('Successfully evolved original XML Schema.');
       
    EXCEPTION
       WHEN OTHERS
       THEN
          ROLLBACK;
          DBMS_OUTPUT.PUT_LINE('Error issued during InPlace XML Schema Evolution:');
          DBMS_OUTPUT.PUT_LINE(SQLERRM);
    END;
    /
    H3. The scripts above provide the following Test output:
    Connected to Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 
    Connected as TEST_DB_SCHEMA@dbs02local
     
    SQL> 
    -------------------------------
    INITIAL XML SCHEMA REGISTRATION
    -------------------------------
     
    XML Schema http://home/xsd/test_binXML_v1.xsd is already registered.
     
    Executed in 0 seconds
    
    ----------------------
    ONE-OFF DDL STATEMENTS
    ----------------------
      
    Table created
     
    Executed in 0.016 seconds
     
    Index created
     
    Executed in 0.016 seconds
     
    Table altered
     
    Executed in 0 seconds
     
    Sequence created
     
    Executed in 0 seconds
    
    --------------------------
    CREATING INITIAL TEST DATA
    --------------------------
     
    Table truncated
     
    Executed in 0.032 seconds
    
    Inserted a total of 10259 transaction XML pieces across 200 Test Batches.
    Commit complete.
     
    PL/SQL procedure successfully completed
     
    Executed in 8.487 seconds
    
    -----------------------------------------------------------------------------------
    NEW XML SCHEMA REGISTRATION - IDENTICAL TO OLD SCHEMA EXCEPT FOR NEW <Test> ELEMENT
    -----------------------------------------------------------------------------------
     
    XML Schema http://home/xsd/test_binXML_v2.xsd is already registered.
    
    ---------------------------------------------------------------
    ATTEMPT TO INSERT V2 XSD-COMPLIANT XMLDOC INTO TEST_BATCH TABLE
    ---------------------------------------------------------------
     
    Insert failed as expected.
    
    ORA-31061: XDB error: XML event error
    ORA-19202: Error occurred in XML processing
    LSX-00213: only 0 occurrences of particle "Transaction", minimum is 1
     
    PL/SQL procedure successfully completed
     
    --------------------------------------------------------------------------------------
    PERFORM IN-PLACE EVOLUTION AND DE-REGISTER/PURGE OLD SCHEMA IF EVOLUTION IS SUCCESSFUL
    --------------------------------------------------------------------------------------
     
    Successfully extrapolated XDIFF XML Document.
    Error issued during InPlace XML Schema Evolution:
    ORA-31166: internal error code to handle ignorable attributes
     
    PL/SQL procedure successfully completed
     
    Executed in 0.046 seconds
    SQL> 
    NOTE: When I ran the above tests, I had already created the test of XML schemas. That's why the output messages, say...

    H4. Now, as it is the first time I've ever tried evolution of XML schema in Oracle XMLDB, is there someone who could potentially open the door please, re. solve the < font color = "red" >ORA-31166< / police > error?

    Hello

    First of all, thank you for your efforts on the provision of a decent test case.

    However, there are a few inconsistencies:

    -Step 5 attempts to insert into SUBMISSION_BATCH, but the table created above is TEST_BATCH
    -Same for the sequence name

    Now back to the real question...

    I think the problem comes because you run XMLDiff against two versions saved of your drawings.
    When Oracle stores a schema, it adds a large number of attributes for internal use (you can see them by querying USER_XML_SCHEMAS. DIAGRAM) but we as end users don't have to worry about them.
    However, by building the Xdiff document based on these two 'internal' versions, we explicitly say Oracle whose internal attributes must be changed during the evolution of the scheme, leading to potential conflicts.

    A few other comments:
    -Given that you're using the binary XML schema, you must also set "genTables-online false" and more "genTypes-online false."
    -Also delete all annotations from xdb:defaultTable and xdb:storeVarrayAsTable on the diagrams, they are of no use in this situation.
    -Do not save the schema of the v2, it is not necessary. Just use a transient instance when calling XMLDiff

    So, to summarize:

    -XMLDiff run against both original patterns (do not save a new in any case, the process of evolution will take care of replacing the old).
    -of course, don't forget to change the INPLACE_TRACE to INPLACE_EVOLVE when ready :)

    Hope that helps.

    Published by: odie_63 on August 23, 2012 16:31 - fixed some typos

  • ORA-00604: error occurred at recursive SQL when the proc via db_link

    Hello
    I'm on 9.2.0.8 and got a strange problem with simple test cases
    on source db:
    CREATE OR REPLACE PROCEDURE ADMIN.gg_ref(out_tokens OUT SYS_REFCURSOR) is
      BEGIN
      OPEN out_tokens for select dummy from dual;
    END ;
    /
    
    
    Now testing code localy:
    SQL> var r refcursor
    SQL> declare
      2   output sys_refcursor;
      3  begin
      4   adminx.gg_ref(output);
      5  :r:=output;
      6  end;
      7  /
    
    PL/SQL procedure successfully completed.
    
    SQL> print r
    
    D
    -
    X
    
    
    So its working.
    
    I've got db_link to that db , and now call that proc via dblink from other 9.2.0.8 DB:
    
    
    var r refcursor
      1  declare
      2   output sys_refcursor;
      3  begin
      4   admin.gg_ref@LINK_NAME(output);
      5  :r:=output;
      6* end;
    SQL> /
    declare
    *
    ERROR at line 1:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-00900: invalid SQL statement
    What wrong with my code?
    Is there a any restriction that I'm not aware?
    Concerning
    GregG

    GregG says:

    What should my code looks like now?
    Should I rewrite this as function returns the index of collection or something?

    You can use DBMS_SQL - but use the remote package and not the local. It's a little more complex ito call interface you use a Ref Cursor, but is the same server-side. DBMS_SQL also provides a more comprehensive set of features to use the ref cursor interface.

    Most, however, is add code - DBMS_SQL is a lower level interface (much closer to the real Oracle Call Interface/OIC):

     --// on remote database the procedure returns a DBMS_SQL cursor instead of a ref cursor
    SQL> create or replace procedure FooProc( cur in out number, deptID number ) is
      2          rc      number;
      3  begin
      4          cur := DBMS_SQL.open_cursor;
      5
      6          DBMS_SQL.parse(
      7                  cur,
      8                  'select ename from emp where deptno = :deptID',
      9                  DBMS_SQL.native
     10          );
     11
     12          DBMS_SQL.Bind_Variable( cur, 'deptID', deptID );
     13
     14          rc := DBMS_SQL.Execute( cur );
     15  end;
     16  /
    
    Procedure created.
    
    --// from the local database side we call this remote proc
    SQL> declare
      2          c               number;  --// instead of using sys_refcursor
      3          empName         varchar2(10); --// buffer to fetch column into
      4  begin
      5          FooProc@testdb( c, 10 );  --/ call the proc that creates the cursor
      6
      7          --// we need to define our fetch buffer for the 1st column in the
      8          --// SQL projection of that cursor (10 byte fetch buffer for 1st column)
      9          DBMS_SQL.define_column@testdb( c, 1, empName, 10 );
     10
     11          --// we now fetch from this cursor, but via the DBMS_SQL
     12          --// interface
     13          loop
     14                  --// fetch the row (exit when 0 rows are fetched)
     15                  exit when DBMS_SQL.Fetch_Rows@testdb( c ) = 0;
     16
     17                  --// copy value of 1st column in row into the local PL/SQL buffer
     18                  DBMS_SQL.column_value@testdb( c, 1, empName );
     19
     20                  --// record value it via dbms output
     21                  DBMS_OUTPUT.put_line( 'name='||empName||' deptID=10' );
     22          end loop;
     23
     24          --// close it explicitly as you would a ref cursor
     25          DBMS_SQL.Close_Cursor@testdb( c );
     26  end;
     27  /
    name=CLARK deptID=10
    name=KING deptID=10
    name=MILLER deptID=10
    
    PL/SQL procedure successfully completed.
    
    SQL>
    
  • ORA-00942 - create a procedure

    When I create this procedure

    It's a return ORA-00942 on line 6, but I have the privilege to choose on dba_tables.


    CREATE OR REPLACE PROCEDURE p_read_only
    AS
    BEGIN
    FOR x IN (SELECT table_name
    FROM dba_tables
    Owner WHERE = 'MAN')
    LOOP
    RUN IMMEDIATELY ' GRANT SELECT ON SWH.»
    || x.table_name
    || "TO READ_ONLY.
    END LOOP;

    FOR x IN (SELECT view_name
    FROM dba_views
    Owner WHERE = 'MAN')
    LOOP
    RUN IMMEDIATELY ' GRANT SELECT ON SWH. "| x.view_name
    || "TO READ_ONLY.
    END LOOP;
    END;
    /

    Thank you

    Published by: Jx on July 19. 2011 08:10

    In the future please check for errors before you post thereon. This error is with ORA-1031, PLS-201 and ORA-12514 error more popular on this forum, always because people post here never use online resources.

    No, you do not have privilege. You have the privilege, thanks to a role and roles are disabled during the compilation of the procedures as roles can change on the fly.

    You must
    or the other

    (1) create or replace... AUTHID current_user
    (2) grant select privileges directly on dba_tables.

    The last method is not preferable, because you will end up with a myriad of direct privileges which are not included in your export, they are owned by SYS and SYS is not exported.

    Also in DDL in a procedure is generally considered bad because it has all kinds of side effects.
    A regular SQL script should be sufficient.

    ----------------
    Sybrand Bakker
    Senior Oracle DBA

  • ORA-04052: error occurred when searching to the top of the remote object REPADMIN. SYS@CEL2. W

    Hello
    on 10 gr 2 on WIN 2003 server:
    C:\>sqlplus repadmin/***@CEL2.WORLD
    
    SQL*Plus: Release 10.2.0.4.0 - Production on Tue Jun 22 09:54:18 2010
    
    Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.
    
    
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    And then:
    CONNECT repadmin/******@CEL1.WORLD
    
    BEGIN
       DBMS_REPCAT.ADD_MASTER_DATABASE (
          gname => 'REPG',
          master => 'CEL2.WORLD',
          use_existing_objects => TRUE,
          copy_rows => FALSE,
          propagation_mode => 'ASYNCHRONOUS');
    END;
    / 
    
    BEGIN
    *
    ERROR at line 1:
    ORA-04052: error occurred when looking up remote object [email protected]
    ORA-00604: error occurred at recursive SQL level 2
    ORA-12545: Connect failed because target host or object does not exist
    ORA-06512: at "SYS.DBMS_REPCAT_UTL", line 4271
    ORA-06512: at "SYS.DBMS_REPCAT_MAS", line 2156
    ORA-06512: at "SYS.DBMS_REPCAT", line 146
    ORA-06512: at line 2
    Thanks for the help.

    connect to the remote database as sys and

    SQL > grant execute on sys. DBMS_REPCAT repadmin;

  • setTriggerEvents &gt; ORA-20171: error WM: trigger &lt; NAME &gt; does not exist

    Hello

    Problem*: execution of DBMS_WM.setTriggerEvents results in a < trigger_name > error does not exist, even if the trigger actually exists.

    Environment*: Oracle 10 g R2 on Windows 2003. Internal programs of PL/SQL stored in packages in a schema; data tables compatible version in many other patterns. The DIRECT workspace is frozen, allowing that the operations of WM. Applications and users change data in the context of child workspaces.

    _ The goal: on a workspace of the merger in LIVE, fire a level trigger line AULIEUDE updates the data in another schema.table. For example, changes to data in Schema1 activate the trigger stored in Schema2, which in turn changes in schema3.

    It is believed that an AULIEUDE trigger is necessary due to complications OWM. Specifically, a trigger on the underlying table for the LT would fire outside the context of a review, which is problematic because triggered changes are made, even if the user ignores finally his work space. In addition, the operations are not easily discernible on the table LT for INSERTS, UPDATES and DELETES the extra lines result (i.e., INSERTS).

    Detail: *
    Organization: SchemaSW contains a trigger that calls a public procedure in a specific application package "Package1" The specific application package calls various public functions in another package in the same pattern. This last package encapsulates OWM sequences appeal and management to ensure that all internal applications regularly perform operations of OWM errors. The trigger is associated with SchemaV1.View. A MERGE_WORKSPACE_W/WO_REMOVE event, the trigger modifies data stored in SchemaV2.View.

    Permissions: the user SchemaSW has WM_ADMIN_ROLE, CONNECT, RESOURCE and DBA roles and privileges SELECT ANY TABLE system, update ANY TABLE and SYSDBA. The SchemaV1 user has EXECUTE on SchemaSW.

    Declaration of delinquency: EXECUTE DBMS_WM.setTriggerEvents ("< TRIG_NAME > ', dbms_wm.") WORKSPACE_MERGE_WO_REMOVE | «, » || dbms_wm. WORKSPACE_MERGE_W_REMOVE);

    Error:
    ERROR on line 1:
    ORA-20171: error WM: trigger ' < SchemaV1 >. < TRIG_NAME > ' does not exist
    ORA-06512: at "SYS." WM_ERROR', line 342
    ORA-06512: at "SYS." WM_ERROR', line 359
    ORA-06512: at "SYS.LT", line 13264
    ORA-06512: at line 1

    Documents*: Guide to the application developer - Workspace Manager (B14253-01, 10 g Release 2).

    [pg 4-133] «By default, user-defined triggers are executed for DML events both workspace, unless the default behavior is changed using the parameter system Workspace Manager FIRE_TRIGGERS_FOR_NONDML_EVENTS (described in Section 1.5).» You can use the SetTriggerEvents procedure to override the current setting of the FIRE_TRIGGERS_ FOR_NONDML_EVENTS of specific triggers; However, if you later change the value of the parameter system FIRE_TRIGGERS_FOR_NONDML_EVENTS, this new value replaces all specified parameter previously using the SetTriggerEvents procedure. If this procedure is successful, it validates the transaction open database calling fs. An exception is thrown if one or more of the following apply: hominess ' user is not the owner of the trigger, or does not have the role WM_ADMIN_ROLE. There is no such thing as ¡triggerName. Instead of more triggerEvents values are not valid. »

    [pg 1-23] "1.10 triggers on Version-Enabled tables compatible Version tables may have defined triggers; However, the following considerations and limitations apply: ¦ only by line triggers are supported. Statement triggers is not supported. ¦ Set single-line triggers are supported. Avant-mise day and update after the cessation of the triggers for specific columns are not supported. »

    Troubleshooting*: documentation requires the user trigger (otherwise the trigger owner) to have the WM_ADMIN_ROLE, which is satisfied in this case. I checked the existence of triggering via:

    SELECT the owner, table_owner, table_name, triggering_event, STATUS
    OF dba_triggers
    WHERE UPPER (TRIGGER_NAME) = UPPER ("< TRIG_NAME >" ");

    SchemaSW SchemaV1
    < VIEW >
    INSERT
    PEOPLE WITH DISABILITIES

    (Note that I have disabled the trigger for does not stop others from exercise data while I try to fix this).

    Any directive of the community is very much appreciated.

    Thanking you,
    Noel

    So you're creating instead of trigger directly on the view from above (the original name of the table)? Let me know if this isn't the case.

    OWM does not support INSTEAD of triggers. Instead of triggers need to be defined on a view and the only objects that can be activated version are tables. However, I see nothing in your description that says to an INSTEAD of triggers. What you try to do so should be able to finish the level triggers table row dml insert/update/delete. You would simple create triggers on the table before EnableVersioning or add them during a session of beginDDL/commitDDL, and they would be then implemented as PL/SQL procedures inside the inside instead of triggers that we create. They are not defined on the table _LT.

    After you create the trigger, you would be able to use dbms_wm.setTriggerEvents to specify the events you want relax to fire to.

    Kind regards
    Ben

Maybe you are looking for