Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Merge Problem

Re: Merge Problem

From: mike <hillmw_at_charter.net>
Date: 24 Mar 2005 08:57:25 -0800
Message-ID: <1111683445.671427.146550@o13g2000cwo.googlegroups.com>


Most of the transactions 96% will be update transactions, so shouldn't we go ahead and try to update first, and then if it is not there do the insert?

begin
  UPDATE mytable SET role = 'Super' where id='111111'; exception when VAL_NOT_FOUND then
  Insert into mytable (id, role ) values ( '111111','Super' ); end;

So I need to replace dup_val_on_index with some other exception. Do you know what that exception is?

Mike Received on Thu Mar 24 2005 - 10:57:25 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US