Home » SQL & PL/SQL » SQL & PL/SQL » Better solution for "merge into .."?
Better solution for "merge into .."? [message #230626] Thu, 12 April 2007 06:30 Go to next message
Messages: 41
Registered: March 2007
Hi everyone,
is there something better then using "merge into" in plsql?
Im receiving dump data every 15 minutes. Those data are loaded into basic tables. Then every hour, i'm running plsql procedure, that is inserting those data based on some rules - like agregated, cumulated, and so on into the final tabl(e|s). It may happen in some cases, that i have to reimport those data for some last couple of days, then i have to rerun my procedure on those days. So i'm using merge for this situation = merge into .. using ... on (keys) when matched - update, when not matched insert. I was thinking to use insert, and exception handler - DUP_VAL_ON_INDEX - for update. But i guess it will not change anything.

thanks for any advice
Re: Better solution for "merge into .."? [message #230627 is a reply to message #230626] Thu, 12 April 2007 06:37 Go to previous message
Michel Cadot
Messages: 65135
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
merge is faster than any PL/SQL code.

Previous Topic: extracting information from another table based on the data in the current row
Next Topic: Difference between two rows
Goto Forum:

Current Time: Wed Aug 16 22:56:56 CDT 2017

Total time taken to generate the page: 0.07989 seconds