Catching unique constraint voilation at the VO level

I have a Result table which is used as Result table/ for updation/ for insertion of new row.
The underlying db table on which the Eo and consequently VO are based has a unique constraint which I want to catch and throw a suitable exception when the user is trying to update or insert using the result table which in my case is an advanced table. I am unable to figure out at what place I need to put the check. Though I am trying to handle the said condition before calling the getTransaction().commit(), I guess the DB is throwing the error even earlier which I presume is at the point of insertion into the Db which I guess happens at the EO setAttribute Level. So is it right to put the check at the setters in the EO???
Kindly provide feedback as how to overcome this problem

GFMIS.PK_ELTRADERID
ON (lct.trader = exl.trader)Your ON clause should be work on the same column of your PK, that should be enough to avoid the unique constraint violation.
Nicolas.

Similar Messages

  • [svn] 869: Bug: BLZ-92 - catch IOException and log at the info level to keep from polluting the logs

    Revision: 869
    Author: [email protected]
    Date: 2008-03-19 15:21:25 -0700 (Wed, 19 Mar 2008)
    Log Message:
    Bug: BLZ-92 - catch IOException and log at the info level to keep from polluting the logs
    QA: Yes
    Doc: No
    Details:
    Tomcat 5+ throws a ClientAbortException when it receives a TCP RST while writing a response to a client that has exited. This custom exception extends IOException, and we were only doing lighter INFO-level logging for SocketExceptions so the ClientAbortException was getting past this leading to ERROR level logging. This little tweak will mean less pollution of the server logs during QE load tests.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-92
    Modified Paths:
    blazeds/branches/3.0.x/modules/core/src/java/flex/messaging/endpoints/BaseHTTPEndpoint.ja va

    Hi AbhijitRoy2005,
    Other then climbing in the phone and calling the vendor, you could try:
    1. To use a BufferedInputStream to wrap the SocketInputStream before you wrap that in the DataInputStream. So basically:
    DataInputStream dis = new DataInputStream(new BufferedInputStream(socket.getInputStream());On one of my implementations this made a difference of a factor of 200+! So instead of processing 500 messages per second, I could process 10000 messages per second!
    2. Or to take it to the next level and take a look at using NIO. That is New IO, available since Merlin (Java 1.4). But that would take you way more time then the first attempt.
    The thing addressed by the possible solutions above is the blocking nature of the Stream based socket handling. Using a buffered input stream reads ahead. The NIO thing is all about non-blocking IO, which uses Channels and Buffers instead of Sockets and Streams (note that these are not equivalent!).
    Of course, if you didn't change something in your own code, it might just very well be that the vendor just screwed up his ;)
    Regards,
    Frens

  • How to Catch Unique Constraint in Exception

    Hi,
    I am writing a trigger TR_EMP on a table EMP which has columns EMP_ID, EMP_NAME, ALT_EMP_ID.
    Now I am updating ALT_EMP_ID for an EMP_ID(PK) which is unique.
    If ALT_EMP_ID is null
    then
          :new.ALT_EMP_ID = l_alt_emp_id;
    end if;As this ALT_EMP_ID is unique, same ID shouldn't be inserted again here. When data being inserted with 2 different sessions for 2 different EMP_ID there is a possible chance of inserting same ALT_EMP_ID for both which results in Unique error. I need to handle this exception. DUP_VAL_ON_INDEX or OTHERS Execption not able to handle this.
    Can you help me out on how to handle such exception?

    >
    jeneesh wrote:
    I am able to use dup_val_on_index
    >
    Can you please write an Exception for this query?
    If ALT_EMP_ID is null
    then     
          :new.ALT_EMP_ID = l_alt_emp_id;
    end if;jeneesh wrote:
    Moreover, what is your requirement? This design seems to be flawed. If you can explain teh actual requirement, forum members will be able to help you better..
    >
    Alternate Emp ID will be populated for Every employee. If on a same session when this ID is populated for 2 different Emplyoees then it will throw Unique constraint error, which should be handled.

  • OWB Update/Insert throwing unique constraint ..

    Hello Al,
    I am currently facing issue when it is supposed to update/Insert the records in OWB10gR2.
    Also there are no duplicates in the source data while doing this.
    Any help is appreceated.
    Thanks,
    Suresh
    Edited by: user8745316 on Jul 27, 2010 12:58 AM

    Hi Nawneet,
    Thanks for the reply.
    My issue is something like this , there were duplicates from the source and we deleted them but still it gives this error @ Unique constraint voilated errror.
    I also can understand that as we have same matching records by key columns from source and target which should ideally be doing the update and if non matching should be inserting which is not happening now.
    can you please suggest me the issue.
    Thanks for your help.
    Suresh

  • Table with unique Constraint

    Dear All
    i have a a project ADF-BC / JSF - JDeveloper 11.1.2.3.0 latest, and i have EO contains PK constrain in db in 2 fields (userid & Roleid) and i implemented bundle to handle error message with jbo error code and it works fine in AM test
    and i have VO contains LOV in one attribute of this unique constrain columns (Roleid), now i dropped VO in jsf page as a af:table as below with input text with list of values for roleid and auto submit = true , and i face unexpected behavior from lov attribute in case of entering repeated value ..
    when i enter another repeated value , it give me error message i created in the bundle and everything ok until now
    but when i tab out of input text with list of values , it go back to old value as may be validation fired in back ground , it is not a problem until now
    when i try to make anything else, he still gives me error message of duplicated key
    i change the value again to correct value to avoid duplication error message , i am surprised , still i get the error message and shows me the repeated value again !!
    simply it still save the old repeated value however i corrected , please any one help me to know what is happening and how to solve ?
    Attribute in EO :
    <Attribute
    Name="RoleId"
    Precision="10"
    ColumnName="ROLE_ID"
    SQLType="VARCHAR"
    Type="java.lang.String"
    ColumnType="VARCHAR2"
    TableName="USER_ROLES"
    PrimaryKey="true">
    <DesignTime>
    <Attr Name="_DisplaySize" Value="10"/>
    </DesignTime>
    <validation:ExistsValidationBean
    Name="RoleId_Rule_1"
    ResId="CS.model.BC.EO.UserRolesEO.RoleId_Rule_1"
    OperandType="EO"
    AssocName="CS.model.BC.ASS.UsersRolesFk2ASS"/>
    </Attribute>
    Interface af : table
    <af:table value="#{bindings.UserRoles2.collectionModel}" var="row"
    rows="#{bindings.UserRoles2.rangeSize}"
    emptyText="#{bindings.UserRoles2.viewable ? 'No data to display.' : 'Access Denied.'}"
    fetchSize="#{bindings.UserRoles2.rangeSize}"
    rowBandingInterval="0"
    filterModel="#{bindings.UserRoles2Query.queryDescriptor}"
    queryListener="#{bindings.UserRoles2Query.processQuery}"
    filterVisible="true" varStatus="vs"
    selectedRowKeys="#{bindings.UserRoles2.collectionModel.selectedRow}"
    selectionListener="#{bindings.UserRoles2.collectionModel.makeCurrent}"
    rowSelection="single" id="t1" columnSelection="none"
    columnStretching="column:c3">
    <af:column sortProperty="#{bindings.UserRoles2.hints.RoleId.name}"
    filterable="true" sortable="true"
    headerText="#{bindings.UserRoles2.hints.RoleId.label}"
    id="c2">
    <af:inputListOfValues id="roleIdId"
    popupTitle="Search and Select: #{bindings.UserRoles2.hints.RoleId.label}"
    value="#{row.bindings.RoleId.inputValue}"
    model="#{row.bindings.RoleId.listOfValuesModel}"
    required="#{bindings.UserRoles2.hints.RoleId.mandatory}"
    columns="#{bindings.UserRoles2.hints.RoleId.displayWidth}"
    shortDesc="#{bindings.UserRoles2.hints.RoleId.tooltip}"
    autoSubmit="true" editMode="select">
    <f:validator binding="#{row.bindings.RoleId.validator}"/>
    </af:inputListOfValues>
    </af:column>
    <af:column sortProperty="#{bindings.UserRoles2.hints.RoleName.name}"
    sortable="true"
    headerText="#{bindings.UserRoles2.hints.RoleName.label}"
    id="c3">
    <af:outputFormatted value="#{row.bindings.RoleName.inputValue}"
    id="of7" partialTriggers="roleIdId"/>
    </af:column>
    <af:column sortProperty="#{bindings.UserRoles2.hints.Active.name}"
    filterable="true" sortable="true"
    headerText="#{bindings.UserRoles2.hints.Active.label}"
    id="c4">
    <af:outputFormatted value="#{row.bindings.Active.inputValue}"
    id="of8" partialTriggers="roleIdId"/>
    </af:column>
    </af:table>
    Edited by: user8854969 on Oct 7, 2012 1:34 PM
    Edited by: user8854969 on Oct 7, 2012 2:16 PM

    I believe there is a little confusion here. The error I am encountering has to do with a unique constraint violation and not a foreign key constraint. If I have the data:
    PK FK sequence
    1 5 1
    2 5 2
    3 5 3
    with a unique constraint on (FK, sequence) and want to change it to:
    PK FK sequence
    1 5 1
    4 5 2 --insert
    2 5 3 --update on sequence
    3 5 4 --update on sequence
    I am currently getting a unique constraint violation because the insert is issued before the updates, and the updates alone cause problems because they are issued out of order (i.e. if I do the shifting operation without the insertion of a new record).

  • Unique Constraint Violation on Merge

    I'm getting a unique constraint violation on the following but I don't understand why. I know there are duplicates on remote.customer_id but I'm doing a distinct on that column but still the error. In my local table, customer_id is the primary key so it must be unique. If I remove the primary key constraint altogether, the error goes away.
    Can anyone tell me why both DISTINCT and UNIQUE fail to eliminate duplicates in this merge statement? I have confirmed that remote.customer_id is the source of the duplicates.
    merge into CUSTOMER c
    using (
    select DISTINCT remote.customer_id,
    remote.name_1,
    remote.name_2,
    remote.name_3,
    remote.name_4,
    remote.house_number_and_street,
    remote.city,
    remote.region,
    remote.country_code,
    remote.postal_code,
    p.customer_id_of_bus_partner
    from D_CUSTOMER@BW_LINK remote
    left join D_CUSTOMER_PARTNER_FUNCTIONS@BW_LINK p
    on p.customer_id = remote.customer_id
    where p.partner_function_id = 'ZS'
    ) remote
    on (c.customer_id = remote.customer_id)
    when matched then
    update set c.name_1 = remote.name_1,
              c.name_2 = remote.name_2,
              c.name_3 = remote.name_3,
              c.name_4 = remote.name_4,
              c.house_number_and_street = remote.house_number_and_street,
              c.city = remote.city,
              c.region = remote.region,
              c.country_code = remote.country_code,
              c.postal_code = remote.postal_code
    when not matched then
    insert (c.customer_id,
                   c.name_1,
                   c.name_2,
                   c.name_3,
                   c.name_4,
                   c.house_number_and_street,
                   c.city,
                   c.region,
                   c.country_code,
                   c.postal_code,
                   c.customer_id_of_bus_partner
    values (remote.customer_id,
                   remote.name_1,
                   remote.name_2,
                   remote.name_3,
                   remote.name_4,
                   remote.house_number_and_street,
                   remote.city,
                   remote.region,
                   remote.country_code,
                   remote.postal_code,
                   remote.customer_id_of_bus_partner
    LOG ERRORS INTO DML_ERROR_LOG ('Customer Merge') REJECT LIMIT 5;
    Edited by: bjiggs on Mar 25, 2010 10:56 AM

    When you mentioned the following in previous post...
    +unable to get a stable set of rows in the source tables+
    ...I suspected this :-)
    This is EQUIVALENT to "Mutating Table trigger/function" error...
    ...in the sense that the the "target rows" which are
    supposed to be changed (by this statement)
    are FOUND/MATCHED in the "source result set" MULTIPLE TIMESThe main reason this error comes up is...
    In the SOURCE result set, there are MORE than one ROW that MATCHED the TARGET result set.
    In this scenario the row with PK=3 matches more than one SOURCE rows, which one is supposed to be used for updating?
    Yes indeed, oracle is unable to get a stable set of rows in source tables.
    However the PK=4 is not matched in the target result set, so the statement will attenpt to insert both rows resulting in UNIQUE contraint error.
    This was the case with OP in this posts.
    This can be seen in your example by commenting one of the rows in table S with PK=3.
    sudhakar@ORCL>drop table D;
    Table dropped.
    sudhakar@ORCL>drop table S;
    Table dropped.
    sudhakar@ORCL>create table D ( pk number, a varchar2(10),
      2  constraint d_pk primary key (pk));
    Table created.
    sudhakar@ORCL>
    sudhakar@ORCL>insert into D values( 1, 'a');
    1 row created.
    sudhakar@ORCL>insert into D values( 2, 'a');
    1 row created.
    sudhakar@ORCL>insert into D values( 3, 'a');
    1 row created.
    sudhakar@ORCL>
    sudhakar@ORCL>commit;
    Commit complete.
    sudhakar@ORCL>
    sudhakar@ORCL>create table S ( pk number, a varchar2(10));
    Table created.
    sudhakar@ORCL>
    sudhakar@ORCL>insert into S values( 1, 'b');
    1 row created.
    sudhakar@ORCL>insert into S values( 2, 'b');
    1 row created.
    sudhakar@ORCL>insert into S values( 3, 'b');
    1 row created.
    sudhakar@ORCL>--insert into S values( 3, 'b');
    sudhakar@ORCL>insert into S values( 4, 's');
    1 row created.
    sudhakar@ORCL>insert into S values( 4, 't');
    1 row created.
    sudhakar@ORCL>
    sudhakar@ORCL>commit;
    Commit complete.
    sudhakar@ORCL>
    sudhakar@ORCL>
    sudhakar@ORCL>merge into d
      2  using s
      3  on (d.pk = s.pk)
      4  when matched then update
      5  set d.a = s.a
      6  when not matched then insert
      7  (d.pk, d.a)
      8  values (s.pk, s.a);
    merge into d
    ERROR at line 1:
    ORA-00001: unique constraint (SUDHAKAR.D_PK) violated
    sudhakar@ORCL>vr,
    Sudhakar B.

  • Unique constraint violation on version enabled table

    hi!
    we're facing a strange problem with a version enabled table that has an unique constraint on one column. if we rename an object stored in the table (the name-attribute of the object is the one that has a unique constraint on the respective column) and rename it back to the old name again, we get an ORA-00001 unique constraint violation on the execution of an update trigger.
    if the constraint is simply applied as before to the now version enabled table, I understand that this happens, but shouldn't workspace manager take care of something like that when a table with unique constraints is version enabled? (the documentation also says that) because taking versioning into account it's not that we try to insert another object with the same name, it's the same object at another point in time now getting back it's old name.
    we somewhat assume that to be a pretty standard scenario when using versioned data.
    is this some kind of bug or do we just miss something important here?
    more information:
    - versioning is enabled on all tables with VIEW_WO_OVERWRITE and no valid time support
    - database version is 10.2.0.1.0
    - wm installation output:
    ALLOW_CAPTURE_EVENTS OFF
    ALLOW_MULTI_PARENT_WORKSPACES OFF
    ALLOW_NESTED_TABLE_COLUMNS OFF
    CR_WORKSPACE_MODE OPTIMISTIC_LOCKING
    FIRE_TRIGGERS_FOR_NONDML_EVENTS ON
    NONCR_WORKSPACE_MODE OPTIMISTIC_LOCKING
    NUMBER_OF_COMPRESS_BATCHES 50
    OWM_VERSION 10.2.0.1.0
    UNDO_SPACE UNLIMITED
    USE_TIMESTAMP_TYPE_FOR_HISTORY ON
    - all operations are done on LIVE workspace
    any help is appreciated.
    EDIT: we found out the following: the table we are talking about is the only table where the unique constraint is left. so there must have been a problem during version enabling. on another oracle installation we did everything the same way and the unique constraint wasn't left there, so everything works fine.
    regards,
    Andreas Schilling
    Message was edited by:
    aschilling

    hi!
    we're facing a strange problem with a version enabled table that has an unique constraint on one column. if we rename an object stored in the table (the name-attribute of the object is the one that has a unique constraint on the respective column) and rename it back to the old name again, we get an ORA-00001 unique constraint violation on the execution of an update trigger.
    if the constraint is simply applied as before to the now version enabled table, I understand that this happens, but shouldn't workspace manager take care of something like that when a table with unique constraints is version enabled? (the documentation also says that) because taking versioning into account it's not that we try to insert another object with the same name, it's the same object at another point in time now getting back it's old name.
    we somewhat assume that to be a pretty standard scenario when using versioned data.
    is this some kind of bug or do we just miss something important here?
    more information:
    - versioning is enabled on all tables with VIEW_WO_OVERWRITE and no valid time support
    - database version is 10.2.0.1.0
    - wm installation output:
    ALLOW_CAPTURE_EVENTS OFF
    ALLOW_MULTI_PARENT_WORKSPACES OFF
    ALLOW_NESTED_TABLE_COLUMNS OFF
    CR_WORKSPACE_MODE OPTIMISTIC_LOCKING
    FIRE_TRIGGERS_FOR_NONDML_EVENTS ON
    NONCR_WORKSPACE_MODE OPTIMISTIC_LOCKING
    NUMBER_OF_COMPRESS_BATCHES 50
    OWM_VERSION 10.2.0.1.0
    UNDO_SPACE UNLIMITED
    USE_TIMESTAMP_TYPE_FOR_HISTORY ON
    - all operations are done on LIVE workspace
    any help is appreciated.
    EDIT: we found out the following: the table we are talking about is the only table where the unique constraint is left. so there must have been a problem during version enabling. on another oracle installation we did everything the same way and the unique constraint wasn't left there, so everything works fine.
    regards,
    Andreas Schilling
    Message was edited by:
    aschilling

  • Performance Impact of Unique Constraint on a Date Column

    In a table I have a compound unique constraint which extends over 3 columns. As a part of functionality I need to add another DATE column to this unique constraint.
    I would like to know the performance implications of adding a DATE column to the unique constraint. Would the DATE column behave like another VARCHAR2 or NUMBER column, or would it degrade the performance significantly?
    Thanks
    Message was edited by:
    user627808

    What performance are you concerned about degrading? Inserts? Or queries? If you're talking about queries, what sort of access path are you concerned about?
    Are you concerned that merely changing the definition of the unique constraint would impact performance? Or are you worried that whatever functional change you are making would impact performance (i.e. if you are now retaining historical data in the table rather than just updating it)?
    Regardless of the performance impact, unique indexes (and unique constraints) need to be correct. If you need to allow duplicates on the 3 current columns with different dates, then you would need to change the unique constraint definition regardless of the performance impact. Fast and wrong generally isn't going to be preferrable to slow and right.
    Generally, though, there probably is no reason to be terribly concerned about performance here. Indexing a date is no different than indexing any other primitive data type.
    Justin

  • CreateException: error message for unique constraint isn't very helpful

    When I create a CMP bean in a table containing a unique constraint, I receive the expected CreateException. However, the error message looks like:
    "Error creating EntityBean: ORA-00001: unique constraint (SID.SYS_C005934) violated"
    This message isn't particularly helpful, especially if there are, say, three unique constraints, and the only difference is the "SYS_CXXXXXX" number. There is no way to tell which number applies to which constraint, and this makes it difficult to give a "readable" error message to the end-user.
    Is there a way of either (a) Setting the error message to be thrown by a unique constraint violation or (b) A means of getting the column name that was the focus of the violation? Either of these would make it easier to map an "readable" error message to the exception.
    Much thanks,
    -Roger

    Hi Roger,
    How about trying to give meaningfull names while creating the table, so that when the exception is throw, it would be easy to find the column
    which generated the exception.
    something like,
    SQL>create table table1
    id number(10) constraint UNIQUE_TABLE1_ID unique
    Table created
    SQL> insert into table1 values(1);
    1 row created.
    SQL> insert into table1 values(1);
    insert into table1 values(1)
    ERROR at line 1:
    ORA-00001: unique constraint (SCOTT.UNIQUE_TABLE1_ID) violated
    Hope this helps
    Regards
    Elango.

  • TopLink inserts when it should update, unique constraint exception

    The title says most of it. I am creating a series of objects and then updating them in rapid succession. It would be great to handle all the values during the insert, but it's not possible for this process. The majority of the time, the cached object is updated correctly and no problem occurs, but every once in a while TopLink tries to re-insert the previously inserted object, instead of updating it. Obviously this throws a unique constraint exception for the PK, and boots me out of the process.
    I can refreshObject and then it works fine. I'm looking for the underlying cause though. I want to be able to use the cache!
    Thanks!!
    Aaron
    Oracle JDBC driver Version: 10.2.0.3.0
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
    TopLink Release-Designation: 10g Release 3

    Hello,
    How are you obtaining these objects to update them? The likely cause is that you are running out of memory and the objects in the shared identity map are getting garbage collected due to weak references. This means that when they get registered, TopLink can't find them in the cache so assumes they are new (the default existence check is check cache).
    If this is the case, there are a few options.
    1) Increase the size of the cache for the class in question to something more appropriate for your application, or use a fullIdentyMap so nothing ever gets pushed out. Of course, a FullIdentityMap should not be used lightly as it prevents its objects from beign gc'd and has consequences to related objects as described in:
    Caching Causing Memory Leak Effect
    Both these options will require more memory resources though, so if garbage collection is running and clearing out the references because you are already low on memory, this might make GC need to run more frequently
    2) Increase the JVM memory. This assumes completely that GC is clearing out the unused weak references from your cache because it is low on memory - GC can still occur so it doesn't guarantee the problem will be any better
    3) Read in the object through the UnitofWork before making changes (instead of using RegisterObject on existing objects), use the registerExistingObject for known existing objects or use the uow mergeClone method. Merge should cause the object to be read from the database if it is not in the cache, but it depends on the existence options used
    Best Regards,
    Chris

  • Unique constraint ERROR How to update the task order customly?

    I am using DAC to load data from Siebel database into Oracle Business Analytic Data Warehouse for BI Apps. Now we encounter a question. I need some help.
    When I run current execute plan, the Custom_shyy_SIL_ActivityFact is failured.Beause the *'unique constraint (SHYY_OLAP_DEV.W_ACTIVITY_F_U1) violated'* ORA_00001 ERROR. I analyse this question.At last, I think this question is caused with some below reason.
    My custom execute plan include some Update Dimension from Dimension tasks. They are SIL_EmployeeDimension_SCDUpdate and SIL_ProductDimension_SCDUpdate and so no. that tasks that marked Update Dimension from Dimension run before the Custom_shyy_SIL_ActivityFact. And, in the w_product_d one integration_id corresponding with two records, but the curent_flag ='Y' recored is only. Now ,I Think the SDCU Task is run before the Load fact tack. I discoved it does't work. please help me !

    Hey
    When Doing a full Load through DAC it drops all the unique indexes and then inserts the data and recreates the indexes again.The Index Creation fails if there are duplicate rows (Rows with same integration_id).
    So start Checking the Data right from the Source Level.
    First check the Source (do this using the integration_id thats repeating,Go through the informatica Mappings(ETL Mappings).
    If its Fine there Come to the Staging Level and Check for Duplicate Columns.
    Then Check in the final Table for Duplicate records.
    My Guess is that you are having duplicate rows at the Source level.
    If your are using informatica try using distinct for the SQL in the Source Qualifier(think that should block any duplicate records).
    Update here If you are able to solve this.
    Thanks
    Hemanth

  • Catching an error from the component level in a plan?

    I have components that installs a software package (using the LINUX rpm install plugin). These components are called in sequence from an SPS
    "Plan". If any one of the rpm's to be installed by the plan might already have been installed, the rpm exits with an error message and a "1" exit code.
    That exit, causes the whole install to stop dead in its tracks.
    I have tried a "try and catch" to be allow the installation to continue
    when that situation exists. Howvever, at the "Plan" level all I can catch is
    any error. If a bad error; that is one that is not an "Exit 1" because the
    rpm was already installed, but rather something that needs to stop the
    entire plan ... the "catch" will ignore those errors as well.
    Without modification of the SUN component install plugin, how in XML does one know what the exit code is from the install plugin
    (a) within the component that calls the install plugin
    (b) insde the plan XML that calls the component XML that calls the plugin
    Are there global variables, passed return codes, inherited parameters or something that facilitates the passing of exit codes from plug-in to XML component to XML plan?

    Hi,
    Hope you have gone through the mentioned Notes for the pre-requisites. I checked the second Note which shows New and can not be implemented.
    You can check whether the similar Notes have already been implemented in your system. Check with your BASIS team
    Regards,
    Suman
    Edited by: Suman Chakravarthy on Sep 11, 2011 11:59 AM

  • How to get the row that has failed due unique constriant voilation

    Does any body knows how I can get the column values for rows that has failed on unique contriant voilation, I am using 10gr2.
    Also we don't have license for shadow table error logging, otherwise I could have gotten the row from there.
    Any help will be highly appreciated.
    Thanks,
    Ravi

    Hi Ravi,
    Prior to OWB 10.2.0.3 you can use the DML error logging features only for the mappings which runs
    in ROW based mode.
    But from OWB 10.2.0.3 onwards DML error logging features can be used for SET based mappings also.
    You can refer the following Metalink notes for the same
    1. Note 550036.1 DML Error Logging In OWB 10.2.0.3 And OWB 11g
    2. Note 549845.1 How To Use Data Rules And Error Tables Features In OWB10gR2
    Thanks,
    Sutirtha

  • Msg 2601, Level 14, State 1, Procedure sp_flush_commit_table, Line 15 Cannot insert duplicate key row in object 'sys.syscommittab' with unique index 'si_xdes_id'. The duplicate key value is (2238926153). The statement has been terminated.

    I am using SQL server 2008 R1 SP3. And when we are doing back up operations we are facing the below error
    Msg 2601, Level 14, State 1, Procedure sp_flush_commit_table, Line 15
    Cannot insert duplicate key row in object 'sys.syscommittab' with unique index 'si_xdes_id'. The
    duplicate key value is (2238926153).
    The statement has been terminated.
    Please assist me with your inputs.
    Thanks,
    Rakesh.

    Hello,
    Did you enable change tracking on the database? If so, please try to disable and re-enable the change tracking.
    The following thread is about the similar issue, please refer to:
    http://social.msdn.microsoft.com/forums/sqlserver/en-US/c2294c73-4fdf-46e9-be97-8fade702e331/backup-fails-after-installing-sql2012-sp1-cu1-build-3321
    Regards,
    Fanny Liu
    Fanny Liu
    TechNet Community Support

  • Trp the exception ORA-00001: unique constraint

    Want to trap the exception
    ORA-00001: unique constraint (SCHEMA.CONSTRAINT_NAME) violated So can any one tell me the Exception name (like NO_DATA_FOUND).

    You can map error numbers to exception names, although this isn't good practice with errors that are in the pre-defined exception list.
    SQL> create table t (id NUMBER, txt VARCHAR2(10));
    Table created.
    SQL> alter table t add primary key (id);
    Table altered.
    SQL> insert into t values (1, 'A');
    1 row created.
    SQL> insert into t values (1, 'B');
    insert into t values (1, 'B')
    ERROR at line 1:
    ORA-00001: unique constraint (SCOTT.SYS_C0053239) violated
    SQL> ed
    Wrote file afiedt.buf
      1  declare
      2    exc_unique_fail exception;
      3    pragma exception_init(exc_unique_fail, -1);
      4  begin
      5    insert into t values (1, 'B');
      6    dbms_output.put_line('insert successful');
      7  exception
      8    when exc_unique_fail then
      9      dbms_output.put_line('unique constraint failure detected');
    10* end;
    SQL> /
    unique constraint failure detected
    PL/SQL procedure successfully completed.
    SQL>

Maybe you are looking for

  • My iPod wants to play music half way through one song and then start the next one, or pick up in the next song were the first song was at.  How do I fix this?

    I've had it for the past few days that when I have a album playing it will play a song half way through and start the next one, however it still shows the first song name and the time that is on there.  I don't know weather it's just a glich in the i

  • Im getting an error

    hi... i am getting an error saying "the ipod cannot be updated. The disk could not be read from or written to." and after that i get "the ipod cannot be undated. An unknown error occurred (-69)" i tried using the support titled: iTunes displays a -69

  • POP sound come out from air vent

    Hi every mac user out there, My MacBook pro 15 inch recently don't know why, start to have a pop sound out from the back of my MacBook pro's air vent, this started after I open the below case just for checking(because last time I saw a little tiny bu

  • Charge off

    I have a charge off with credit union account due to drop off credit report 6/16. I've call them a few times but all they do is give me a number to a collection agency! They refuse to talk to me about the account! The OCA is no where listed on any of

  • What is eprint and how can I use it?

    i just discovered e print on my wireless printer and hooked it all up. What is the purpose of having e print and how do I use it as an e mail tool? Can you give me some examples?