views:

57

answers:

4

If I am using SQL Server Management Studio on my local machine to execute a query which is manipulating data on one or more remote servers, where does the actual computing take place? Is it using my local resources or that of the remote server?

+5  A: 

The remote server.

SQL Server Management Studio doesn't have any Query Execution Engine built in to it. It simply sends your query to the server that you are connect to and gets the results (and the query plan used, if you request it).

In the case of querying data across linked servers, the server will used the linked server configuration to send the query to the linked server and retrieve the relevant results.

Justin Niessner
+5  A: 

It should be on the server you are currently connected to, if you are linking other servers and quering them, it will be processed on the server that has the linked connections.

Mikeware
+1  A: 

If you execute a query in SQL Server Management Studio, the "real execution" always takes place on the remote server.

haarrrgh
+1  A: 

I executes on the remote database, all SSMS does is send the query to the server there it will be parsed and if a plan exists the plan will be resued otherwise a new plan will be created and executed (simplified view)

however that said, if you have joins between your local and remote linked server in some case sql server will pull in rows to the local server to further process the result set

SQLMenace