Update Local Table From Linked Table

jtrombley24

New Member
Joined
Feb 21, 2016
Messages
27
I have two identical tables, one is linked to an oracle database and the other is a local table, created out of the linked table. I have an update query, that updates the local table from the linked table. The following query takes about five minutes to run. There are only ~6000 rows so I shouldn't take too long. What am I missing?

Code:
UPDATE 
MIDEX_V_PROCESS_ORDER_DETAIL_QTY AS m INNER JOIN MIDEX_V_PROCESS_ORDER_DETAILS AS d ON m.PROCESS_ORDER = d.PROCESS_ORDER

SET 
d.BATCH_NUMBER = m.[BATCH_NUMBER], 
d.COMPONENT_BATCH = m.[COMPONENT_BATCH], 
d.COMPONENT_MATERIAL_NUMBER = m.[COMPONENT_MATERIAL_NUMBER], 
d.SCHED_START_DATE = m.[SCHED_START_DATE], 
d.ACTUAL_FINISH_DATE = m.[ACTUAL_FINISH_DATE], 
d.ORDER_QTY = m.[ORDER_QTY],
d.ACTUAL_QTY = m.[ACTUAL_QTY]

WHERE 
d.PROCESS_ORDER = m.PROCESS_ORDER;

Thanks in advance!
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
I presume you mean there are ~6000 rows in the linked table.
Are there indexed fields in the linked table that are not indexed in the target table? Indexing can make a speed difference.
Have you tried a select query on the linked table to compare? Hopefully you are not using a VPN or wireless.
 
Upvote 0

Forum statistics

Threads
1,213,567
Messages
6,114,342
Members
448,570
Latest member
rik81h

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top