Update/Insert/Delete into the same table
Hi,
I'm writing pl/sql code :
nvoice_id will be passed as parameter and based on invoice_id I need to see whether any records exist in history table.If not any then insert record into table.If more than one record exist then I need delete all except most recent one based hist_seq column in that table.
Then I need to update that record for description column .How to put dml operation one after another in an efficient manner?As one statement depend on another do I need to use autonomous transaction?
Thanks,
Kiran