There are two tables involved. I am going to list each table and the fields involved in this problem and then write some pseudo code so you can get an idea of what I am trying to accomplish.
UPDATE SET SHIP_TO.DIVISION_ID = 17 WHERE
SHIP_TO.DIVISION_ID IS NULL AND ARCUSTO.EPLANT_ID = 20 AND ARCUSTO.CUSTNO LIKE '*-30'
UPDATE SET SHIP_TO.DIVISION_ID = 16 WHERE
SHIP_TO.DIVISION_ID IS NULL AND ARCUSTO.EPLANT_ID = 20 AND ARCUSTNO.CUSTNO LIKE '*-20'
I left out the joins from ship_to.arcusto_id to arcusto.id because I am not sure how that works in this instance. I am quite comfortable updating data in a single table but when it comes to this type of problem I can't understand the resulting code to make it happen. There usually is a lot of aliases going on and I just can't make sense of it. If someone could explain the answer when the solution is found I would appreciate it. Or send me to some documentation or video so I can actually learn how this works because it keeps coming up! I feel that if I could just get a 15 minute tutorial explaining what the code structure is doing / meaning is all about I would be able to do these types of procedures myself.
Why doesn't the Oracle optimizer use my index?
Querying too much data
Most Oracle developers know that an index is useful when you can use it to restrict your result set to a small number of the total rows in a table.
So, the obvious side…
This post first appeared at Oracleinaction (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself).
I will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…