Error in enabling constraints

Hi everybody,
i have 2 databases d01 and d02. i have same no and same objects on both the databases.
i am exporting data for 1 subscriber from d01 and importing into d02.during importing data to d02 first i disable all constraints of the tables in d02 then importing the data which i have exported from d01 then i am enabling the constraints in d02.
my problem is that at the time of enabling the data i have encountered some errors as follows.
Error while Alter Table PORTFOLIO_CRITERIA_CONDITIONS enable novalidate
constraint XFK3PRTF_CRITERIA_CONDITIONS
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error while Alter Table PORTFOLIO_CRITERIA_CONDITIONS enable novalidate
constraint XFK3PRTF_CRITERIA_CONDITIONS
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error while Alter Table PORTFOLIO_CRITERIA_CONDITIONS enable novalidate
constraint XFK3PRTF_CRITERIA_CONDITIONS
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error while Alter Table PORTFOLIO_TYPE2ATTRIBUTE enable novalidate constraint
XFK12PORTFOLIO_TYPE2ATTRIBUTE
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error while Alter Table PORTFOLIO_TYPE2ATTRIBUTE enable novalidate constraint
XFK12PORTFOLIO_TYPE2ATTRIBUTE
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error while Alter Table PORTFOLIO_TYPE2ATTRIBUTE enable novalidate constraint
XFK12PORTFOLIO_TYPE2ATTRIBUTE
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
Error while Alter Table PORTFOLIO_TYPE2ATTRIBUTE enable novalidate constraint
XFK12PORTFOLIO_TYPE2ATTRIBUTE
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
PL/SQL procedure successfully completed.
can u please tell me what is the error.
Thanks and regards
Subrata

Hallo,
i guess, that you use dynamic sql here, something like
declare
v_sql varchar2(30);
begin
v_sql := 'Alter Table PORTFOLIO_CRITERIA_CONDITIONS enable novalidate
constraint XFK3PRTF_CRITERIA_CONDITIONS';
execute immediate v_sql;
Then, you have to increase the length of v_sql. It's too small !
Regards
Dmytro

Similar Messages

  • Error while enabling  forien key constraint

    HI forum,
    I am facing a problem while enabling constraint..pls see the statement below.
    SQL> alter table EVENT enable validate constraint EVENT_4FK;
    alter table EVENT enable validate constraint EVENT_4FK
    ERROR at line 1:
    ORA-02298: cannot validate (APPO.EVENT_4FK) - parent keys not
    found
    EVENT_4FK FK is refering another table and that primary key is existing and it is in enabled ...
    Pls help me to solve this issue..
    Thanks

    alter table event enable validate constraint event_4fk exceptions into exceptions;check the offending row(s) in the exceptions table. (See the documentation for how to create an exceptions table if not present).

  • Problem in enabling constraint - after disabling and truncation of table .

    Hello Friends,
    I have a table called DRR_TABLES that has list of table names . The requirement is to truncate the tables present in DRR_TABLES except KEY_IDS table and table_name like '%TYPE%' table.
    written a procedure . successfullly truncating the tables from DRR_TABLES but while enabling constraints after truncation , I am getting problem in enabling constraints .
    ERROR at line 1:
    ORA-02270: no matching unique or primary key for this column-list
    ORA-06512: at "schema123.TRUNCATE_DRR_TABLES ", line 49
    ORA-06512: at line 1
    Heres is the code .
    PROCEDURE TRUNCATE_DRR_TABLES is
    x varchar2(200);
    v_tablecount number := 0;
    cursor c is select TABLE_NAME from DRR_TABLES where population_source='PUBLISHING' and TABLE_NAME != 'KEY_IDS' and TABLE_NAME NOT LIKE '%TYPE%';
    BEGIN
    DBMS_OUTPUT.PUT_LINE (' TRUNCATING DRR TABLES ...........');
    OPEN c ;
    LOOP
    FETCH c INTO x ;
    EXIT WHEN c%NOTFOUND;
    for c1 in (select table_name, constraint_name from user_constraints where TABLE_NAME = x and status ='ENABLED' ORDER BY CONSTRAINT_TYPE DESC )
    loop
    begin
    execute immediate ('alter table '||c1.table_name||' disable constraint '||c1.constraint_name|| ' cascade');
    NULL;
    end;
    end loop;
    EXECUTE IMMEDIATE 'TRUNCATE TABLE ' || x ;
    v_tablecount := v_tablecount + 1 ;
    DBMS_OUTPUT.PUT_LINE('TABLE TRUNCATED :'|| x );
    END LOOP ;
    DBMS_OUTPUT.PUT_LINE (' TOTAL TABLES TRUNCATED ' || v_tablecount );
    CLOSE c;
    OPEN c ;
    LOOP
    FETCH c INTO x ;
    EXIT WHEN c%NOTFOUND;
    for c2 in (select table_name, constraint_name from user_constraints where TABLE_NAME = x and status = 'DISABLED' ORDER BY CONSTRAINT_TYPE)
    loop
    begin
    execute immediate ('alter table '||c2.table_name||' enable constraint '||c2.constraint_name);
    NULL;
    end;
    end loop;
    END LOOP ;
    CLOSE c ;
    END TRUNCATE_DRR_TABLES ;
    LINE 49 is the line corresponding to enable constraint statement.
    Edited by: kumar73 on 3 Sep, 2012 11:44 PM

    It is such a pity that a user having 321 posts till date is unaware of basics of Posting a Question.
    1. You need to provide us with your Oracle version
    select * from v$version;2. You need to understand and get accustomed to using tags before and after Code or SQL's for better readability.
    3. You need to provide us with the Table Structure and the Constraints Definition.
    There are many things that looks like Bad Coding practices:
    <font face="Times New Roman" size=2>
    1. Avoid RBAR (Loops).
    2. Implement Bulk Collect.
    3. Why do you need to disable the constraints before truncating? Are you kind of handling the Referential Integrity Constraints?
    4. Duplicate checking of Disabled Constraints.
    5. When the procedure is being executed at Production Environment, are you going to Monitor the DBMS_OUTPUT? Why not Log the Statements into a LOG Table?
    6. Why use a TableCount variable? Would the TableCount Variable be not equal to the Number of Records returned by Cursor C?
    7. What is the need to use a NULL statement after every Execute Immediate?
    8. What is the Need to surround each execute Immediate with Begin .. End block?
    9. Where is your Exception handling Block? Forgot to write?
    </font>
    What has been your effort in finding which Constraint/Table is causing you the trouble?                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Enable constraint issue

    i want to enable a constraint but got error no such constraint.
    but when i select it from user_constraints it is available for that table.
    thanks
    SQL> select constraint_name from user_constraints where table_name='tbl_RefundCredit';
    CONSTRAINT_NAME
    SYS_C0016751
    SQL> ALTER TABLE tbl_RefundCredit enable CONSTRAINT SYS_C0016751;
    ALTER TABLE tbl_RefundCredit enable CONSTRAINT SYS_C0016751
    ERROR at line 1:
    ORA-02430: cannot enable constraint (SYS_C0016751) - no such constraint

    kindly put the constraint name inside single quote or double quote
    then try
    dont mind i dont have the s/w .. so you have test it...

  • OBE-15409: Error in loading constraint information

    Hi,
    I'm having a problem with the Query Builder in Reports Builder. When selecting a table with any type of constraints I get the following type of error message (Emp in user scott/tiger):
    OBE-15409: Error in loading constraint information for EMPNO (PK_EMP)
    OBE-15409: Error in loading constraint information for DEPTNO (FK_DEPTNO)
    The table is shown in the query builder and I can create the select but for instance if I select two tables with a foreign key constraint between them, the foreign key is not shown in the query builder. I have to manually create the join between the tables.
    The error seems to correspond to an upgrade of the database. I get the error with a database upgraded to either 9.2.0.3.0 or 9.2.0.4.0. But on a database upgraded to 9.2.0.2.1 I don't get the error. I have tried with both the original 9i Developer Suite and an upgraded version with Patchset 2 (9.0.2.2.0).
    The same error appears on 3 different setups. 2 local installations of database and developer suite and 1 client/server setup. Everything running Windows 2000 SP 3.
    Any suggestions?
    Regards
    Bent

    Thanks for the reply and the bug number so I can follow the progress. I had done a general search here at Technet and at Metalink and didn't find anything. I didn't think of searching directly in the bug database.

  • Error in enabler configuration:1003

    Hi,
    I have deployed a java application on Sun Application Server 7. I have registered it as an Partner Application in Portal(ver 10g-904).
    The application logs in to OID.
    When I click on login it throws error:
    javax.servlet.ServletException: oracle.security.sso.enabler.SSOConfigException: Error in enabler configuration: 1003
         at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:471)
    But after that if I refresh the page,it takes me to the correct page.
    The same application deployed on websphere is working fine.
    If any one can suggest what the problem can be, that will be great.
    Thanks,
    subhasish

    Hi Teri!
    Did you find any solution for this issue? I´m having the same problem in my environment.
    Thanks in advance!
    Evandro

  • ENABLE CONSTRAINT

    Hello All,
    version details :
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit
    OS :
    SunOS 107 5.10 Generic_125100-10 sun4u sparc SUNW,Sun-Fire-V890
    Issue :
    I have executed a PLSQL which enables all the disabled constraints in a schema....
    Enabling one constraint is taking 15 hours...this step has not take this much time previously...
    There is no blocking session in V$lock....
    The object is locked by only the current session in v$locked_object...
    I know killing and reexecuting the step might solve the issue but i want to know for sure what is blocking it before killing it......'
    Alert log shows no sign execute for redo switch.......
    the hanging statement is below,
    ALTER TABLE UC_ADDRESS_INFO_TX ENABLE CONSTRAINT FK_ADDR_INFO_ROLE_MAP_CD
    Thanks in advance
    Vijay G

    No it`s not because the same table .. the process is below,
    i take an export of production DB, I do structure import ,then i disable the constraints ,then import few required tables alone for the application then i enable the constraints and then i do an analyze . The whole process takes 5 hours now it`s been fifteen hours.
    I have done individual enable before but why is this taking time... i am going to change this into enable novalidate sort but i wnated to know why it is hanging before i do any changes.......
    Regret for the inconvenience,
    Thanks ,
    Vijay G

  • Displaying errors when Enable automatic error handling option is on

    In order to display error messages do I need general or simple error handler to implement if I have Enable automatic error handling on?
    Solved!
    Go to Solution.

    Both will (optionally) display a popup when an error occurs. The general error handler just has more options for special cases. The simple error handler is typically sufficient.
    If you havce automatic error handing enabled, you'll get a popup whenever a function generates an error AND the error output is not wired. Once you wire an error handler, the automatic error handling will no longer occur.
    To display an error, you can also just place a plain error indicator on the front panel. This avoids annoying popup messages.
    LabVIEW Champion . Do more with less code and in less time .

  • Stuck at "about to enable constraints..."

    Hi, I am new to Oracle,pls help me:
    I am importing a dump file into the dbs using IMP on oracle 10g. The import process stopped at
    about to enable constraints...
    for the whole day. would u pls tell me what is the reason...
    thanks in advance

    Hi all,
    it stucks again. "about to enable constraints...".
    the log file looks like:
    IMP-00002: failed to open EXPDAT.DMP for read
    Export file created by EXPORT:V10.02.01 via conventional path
    import done in WE8MSWIN1252 character set and AL16UTF16 NCHAR character set
    . importing XXX's objects into XXX
    IMP-00008: unrecognized statement in the export file:
    . . importing table "AAAAAA" .. rows imported
    . . importing table "BBBBBB" .. rows imported
    . . . . .

  • Does Oracle re-enable an already enabled constraint

    Hi All,
    If my constraints are already enabled and I issue the following enable command:
    alter table <table_name> enable constraint <constraint_name>;
    Will oracle re-enable this already enabled constraint - i.e go through the table data validating each column/columns(as teh case may be) againist the constraint rules, or it will simply do nothing since the constraint is ok?
    Thanks.

    At leats if they previsouly were enabled with novalidate Oracle WILL DEFINTELY CHECK THEM. Example:
    Connected to Oracle Database 11g Release 11.2.0.1.0
    Connected as gints
    SQL> create table t(a number);
    Table created
    SQL> insert into t values (null);
    1 row inserted
    SQL> alter table t add constraint a_nn check(a IS NOT NULL) enable novalidate;
    Table altered
    SQL> alter table t enable constraint a_nn;
    alter table t enable constraint a_nn
    ORA-02293: cannot validate (GINTS.A_NN) - check constraint violated
    SQL> Gints Plivna
    http://www.gplivna.eu

  • ALTER TABLE ENABLE CONSTRAINT FK is very slow

    Hello,
    The following enable constraint command takes around (15min to be completed)
    ALTER TABLE table_name ENABLE CONSTRAINT fk_constraint_name ;table_name: (~133 Millions rows)
    Any idea why it takes long to be completed? and what could be done to improve the performance?
    Thanks in advance

    Enabling a foreign means the database has to check the existence of each value in the child table column against the key in the parent table. Now you say,
    The following enable constraint command takes around (15min to be completed)
    table_name: (~133 Millions rows)In other words, ithe database is validating about ten million rows a minute. That doesn't seem too shabby. So what would you consider to be a reasonable amount of time to accomplish this task?
    Bear in mind the golden rule of tuning: ye cannae break the laws of physics. Acting on large volumes of data must necessarily take some time. You must be realistic.
    Also, why is it a problem? This is the sort of task which ought to be undertaken only occasionally. If you're doing it often enough that fifteen nminutes is unacceptably long perhaps you should reconsider why you're disabling the constraint. See whether there's another way to achieve whatever it is you're doing. After all, the most effective way to reduce something's elapsed time is to avoid doing that thing at all.
    Cheers, APC

  • Enable constraints into exceptions return no matching rowids

    with reference to http://download.oracle.com/docs/cd/B28359_01/server.111/b28310/general005.htm
    Whether I'm using
    Method 1 ALTER TABLE country add
    (CONSTRAINT country_pk PRIMARY KEY (country_code)
    USING INDEX STORAGE (initial 5K) EXCEPTIONS INTO exceptions);
    OR
    Method 2
    ALTER TABLE country enable constraint country_pk EXCEPTIONS INTO exceptions;
    select * from country where rowid in (select rowid from exceptions);
    there's still no matching rowid, why is this so?
    My purpose is to find out which records is causing the constraint failure.
    thanks

    You have to careful with your query:
    select * from country where rowid in (select rowid from exceptions);But the corresponding column in the "EXCEPTIONS" table is called "ROW_ID".
    So it probably should be:
    select * from country where rowid in (select row_id from exceptions);Otherwise you're selecting the actual rowid from the exceptions table which is not what you're looking for.
    Regards,
    Randolf
    Oracle related stuff blog:
    http://oracle-randolf.blogspot.com/
    SQLTools++ for Oracle:
    http://www.sqltools-plusplus.org:7676/
    http://sourceforge.net/projects/sqlt-pp/

  • Estinamted time for enabling constraints

    Just curious, does any one know how long it would take for enabling one disabled constraint on a 166gb table? The table has 34 columns and 2 primary keys.
    i did a "alter table <table_name> enable constraint <constraint_name>" and this statement has been running for 50 mins now.
    Thanks

    969224 wrote:
    Just curious, does any one know how long it would take for enabling one disabled constraint on a 166gb table? The table has 34 columns and 2 primary keys.
    i did a "alter table <table_name> enable constraint <constraint_name>" and this statement has been running for 50 mins now.
    Thanksenabling CONSTRAINT will take longer than disabling the same constraint.
    The exact answer is that "It depends".

  • Getting error while Enable Dashboard Widget

    Dear Experts,
    I am getting error while Enable Dashboard Widget
    u201CInstall SAP Business One Integration Service before enabling the dashboard widgetu201D
    Even I follow all step by step process.
    Thanks
    Kamlesh

    Hi Kamlesh,
    Have you tried the following:
    Deactivate the cockpit in your Business One database - Disable My Cockpit and also disable cockpit in General Settings
    Run EventSender Setup (in first step try to avoid using localhost or IP addresses)
    In third step press Test Connection, in fourth step make sure that your database is checked, press also Receiver but ton and then Test Connecion.
    Finish EventSender setup.
    Click on SLD in the B1i Framwork and ensure connection to the Company databsae (B1DI and JDBC) is successful.
    Go back to B1i Framework UI, click Scenarios in upper menu, then select Control in left menu and (re)activate Xcelsius scenario.
    Restart EventSender service, Integration Service and Proxy services via Servies (Computer Management)
    Now you can enable cockpit in your Business One database - enable cockpit in General Settings and then enable My Cockpit.
    After installation of B1ic, the company is not listed in the SLD
    Delete all entries of table SLSP and SLSPP in SBOCOMMON. Restart integration service. In SAP Business refresh the company list.
    These solutions are documented in the attached Note 1619422.
    Kind regards
    Sean

  • POSTING JOURNALS PROCESS ERROR:GL_ACCOUNT_HIERARCHIES_U1 UNIQUE CONSTRAINT

    제품 : FIN_GL
    작성날짜 : 2003-11-18
    POSTING JOURNALS PROCESS ERROR:GL_ACCOUNT_HIERARCHIES_U1 UNIQUE CONSTRAINT Violated
    ========================================================================
    PURPOSE
    ==================
    GL Posting 시 발생하는 문제를 좀 더 손쉽게 파악하여 해결 할 수 있도록 한다.
    Problem Description
    GL Posting 시 다음과 같은 error 가 발생하였다.
    SHRD0114: Executing Pro*C statement Insert into gl_account_h...
    GL_PROPABLE_DUPLICATE_RANGES: APP-00001 cannot find message name
    GL_PROPABLE_DUPLICATE_RANGES
    SHRD0043: ERROR: ORA-00001: unique constraint (GL.
    GL_ACCOUNT_HIERARCHIES_U1) violated
    Workaround
    N/A
    Solution Description
    1. 다음 문장을 수행한다.
    SELECT DISTINCT
    fvh1.parent_flex_value "Segment w/Overlapping Children",
    SUBSTR(fvh1.child_flex_value_low,1,30) "Overlapping Child Low Value",
    SUBSTR(fvh1.child_flex_value_high,1,30) "Overlapping Child High Value",
    SUBSTR(fvh2.child_flex_value_low,1,30) "Overlapped By Child Low Value",
    SUBSTR(fvh2.child_flex_value_high,1,30) "Overlapped By Child High Value"
    FROM FND_FLEX_VALUE_HIERARCHIES fvh1, FND_FLEX_VALUE_HIERARCHIES fvh2
    WHERE fvh1.parent_flex_value = fvh2.parent_flex_value
    AND fvh1.flex_value_set_id = (select flex_value_set_id
    from fnd_flex_value_sets
    where flex_value_set_name = '&Value_Set_Name')
    AND fvh1.rowid != fvh2.rowid
    AND fvh1.flex_value_set_id = fvh2.flex_value_set_id
    AND NVL(fvh2.CHILD_FLEX_VALUE_LOW,'X') <= NVL(fvh1.CHILD_FLEX_VALUE_HIGH,'X')
    AND NVL(fvh2.CHILD_FLEX_VALUE_HIGH,'X') >= NVL(fvh1.CHILD_FLEX_VALUE_LOW,'X')
    2. 다음과 같은 output 이 나올 것이다.
    EXAMPLE OF OUTPUT
    Enter value for value_set_name: VALUE_SET_ACCOUNT
    old 11: where flex_value_set_name = '&Value_S)
    new 11: where flex_value_set_name = 'VALUE_SE)
    Segment w/Overlapping Children
    Overlapping Child Low Value Overlapping Child High Value
    Overlapped By Child Low Value Overlapped By Child High Value
    1000
    6000 6000
    5000 6000
    1000
    5000 6000
    6000 6000
    3. 위의 output에 대한 설명은 다음과 같다.
    고객이 GL Application에서 Setup->Financials->Flexfields->Key->Value화면을 열어 다음과 같은 작업을 하였다.
    Entered values:
    1000 defined as:
    * parent
    * child ranges:
    From To Include
    6000 6000 Child values only
    3000 3000 Parent values only
    3000 defined as:
    * parent
    * child ranges:
    From To Include
    2000 2000 Child values only
    4000 4000 Child values only
    5000 6000 Child values only
    The hierarchy structure is like this:
    1000
    _________|___________
    6000 3000
    ____|______________
    2000 4000 5000 6000
    위에서 볼수 있듯이 6000 이라는 value 가 중복이 되고 있고 그 사항이 제일 처음에 수행한 script의 output 에 overlapping child ranges 로 나타나고 있는 것이다.
    4. 정정하는 step
    4.1 Setup->Financials-> Flexfields-> Key->Values. 로 가서 화면을 open한다.
    4.2 COA 를 Query 한다.
    4.3 Overlapping 된 child ranges 를 찾아서 정정한다.
    Reference Documents
    Note 118130.1

    You can use the debug script $GL_TOP/patch/115/sql/glxacovl.sql, to isolate overlapping child ranges within summary account rollup groups.

Maybe you are looking for

  • F4IF_INT_TABLE_VALUE_REQUEST -Restrictions dialog box

    Hi, I am using the function module F4IF_INT_TABLE_VALUE_REQUEST in screens, to implement a search help in my program , but instead of directly displaying the hit list , i want the restrictions screen to be displayed first with some default values, an

  • Having trouble setting up a linksys WRT54GS router with v...

    Having trouble setting up a linksys WRT54GS router with verizon DSL using a westell 6100F modem. the modem works fine by its self  but the router will not connect  to the internet when installed like the cd tells you to. online help and phone help ha

  • Services in Trex 7.0

    Hi gurus. We have installed EP7.0 SP15 on one machine and Trex 7.0 on another machine. When we start the services in the Trex Monitor some of them like index, queue, and so on don´t start. Any body can help us?. Thanks in advance. Alfonso

  • Unable to view comment bubble notes

    Some of my students annotated and commented on letters using the Adobe Reader iPad App. When they exported their documents they were unable to view the comments they typed in the note bubble. They tried uploading directly to Dropbox and e-mailing bot

  • Getting Error in starting VIP in 3 NODE RAC Cluster in VMWARE

    hi please can some one help me to have solution for why VIPCA is failing to start VIP on RAC Node 3 it gives the ERROR: CRS-1006; CRS-0215 no more members. Network Configuration is like: /etc/hosts 127.0.0.1 localhost.localdomain localhost #Public IP