Re: Oracle 11G Upgrade
From: Dominic Brooks <dombrooks_at_hotmail.com>
Date: Fri, 28 Mar 2014 14:04:30 +0000
Message-ID: <DUB407-EAS2885C56A996899632D4FB77A1660_at_phx.gbl>
"Update else insert" behaves differently than "insert else update" under concurrent activity.
>
> An INSERT, followed by an UPDATE on fail should be more efficient. I can't
> remember where I saw that years ago (asktom?), but my own testing confirmed
> it in some older version of Oracle (9 or 10).
>
> I was thinking along the same lines though and wondering if a MERGE
> statement in place of the INSERT/UPDATE would work...
>
> Rich
>
> --
> http://www.freelists.org/webpage/oracle-l
>
>
Date: Fri, 28 Mar 2014 14:04:30 +0000
Message-ID: <DUB407-EAS2885C56A996899632D4FB77A1660_at_phx.gbl>
"Update else insert" behaves differently than "insert else update" under concurrent activity.
Similarly merge is different again.
http://orastory.wordpress.com/2011/10/13/concurrent-merge
Cheers,
Dominic
Sent from my iPhone
On 28 Mar 2014, at 13:53, "Rich Jesse" <rjoralist3_at_society.servebeer.com> wrote:
>> Jack, have you considered just changing the logic to perform the update >> first and check the cursor count number of rows updated. If zero perform >> the insert.
>
> An INSERT, followed by an UPDATE on fail should be more efficient. I can't
> remember where I saw that years ago (asktom?), but my own testing confirmed
> it in some older version of Oracle (9 or 10).
>
> I was thinking along the same lines though and wondering if a MERGE
> statement in place of the INSERT/UPDATE would work...
>
> Rich
>
> --
> http://www.freelists.org/webpage/oracle-l
>
>
-- http://www.freelists.org/webpage/oracle-lReceived on Fri Mar 28 2014 - 15:04:30 CET