I'll try to keep this question straightforward, though I am dealing with a big ball of mud.
When I run my test query acrossed linked servers both located locally (on a shared virtual host), the query is fast at about 9 seconds.
When I run the same query acrossed linked servers (one local, one about 1,200 miles away) it is MUCH slower at 5:23
I am trying to learn how to analyze an execution plan, but are there other probable causes for this sort of thing?
Edit: Based on @Mat's comment, here is an example.
DISCLAIMER: I do not vouch for the quality of this code.
SELECT * INTO TempQTYOnHand FROM [RemoteServer].remoteDB.dbo.QuantityOnHand DELETE FROM [RemoteServer].remoteDB.dbo.QuantityOnHand INSERT INTO [RemoteServer].remoteDB.dbo.QuantityOnHand SELECT DISTINCT ProductId, Onhand FROM Inventory WHERE ProductID IN (SELECT ProductId FROM TempQTYOnHand) DROP TABLE TempQTYOnHand
Is this a "chatty" query, and also, I guess chatty would mean that it is round tripping for each row on the INSERT?