Referencing tables on a remote server
From: speegee (speegee_at_discussions.microsoft.com)
Date: 09/29/04
- Next message: Aaron [SQL Server MVP]: "Re: ALTER COLUMN NAME?"
- Previous message: Mike Epprecht (SQL MVP): "RE: Copy database problem"
- Next in thread: Mike Epprecht (SQL MVP): "RE: Referencing tables on a remote server"
- Reply: Mike Epprecht (SQL MVP): "RE: Referencing tables on a remote server"
- Reply: CurtM: "Referencing tables on a remote server"
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 29 Sep 2004 07:47:05 -0700
I have multiple stored procedures which include queries that reference tables
on a remote, linked server. For example,
select id, name from remoteserver.db.dbo.table1
In order to speed up my queries and avoids lockouts while data is being
inserted into those remote tables, I would like to use the WITH (NOLOCK)
clause. However, i cannot use that on remote tables. I thought of creating
local views for each of those remote tables, for example,
create view v_table1 as select id, name from remoteserver.db.dbo.table1
and then using that view instead of the original table in my queries. Would
this be faster? Most of my queries involve multiple tables. The remote
tables do not have primary keys, though they do have multiple indexes.
I should add that I do not have permission to change anything on the remote
server. That includes adding stored procedures to that remote database or
adding indexes or keys.
Also, the remote database is massive, multi-terrabytes massive. The tables
I am interested in have millions of rows.
In a related question, when you create a view that references tables on a
remote server, how quickly/often does it get updated when the data in those
tables gets changed? Am I creating a CPU burden on the remote server or only
my own? My application does not insert/update/delete data on the remote
server, only queries it. On the remote server, however, there is a great
deal of data insertion going on throughout the day and night.
Any suggestions?
- Next message: Aaron [SQL Server MVP]: "Re: ALTER COLUMN NAME?"
- Previous message: Mike Epprecht (SQL MVP): "RE: Copy database problem"
- Next in thread: Mike Epprecht (SQL MVP): "RE: Referencing tables on a remote server"
- Reply: Mike Epprecht (SQL MVP): "RE: Referencing tables on a remote server"
- Reply: CurtM: "Referencing tables on a remote server"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|