Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

limitations of linkserver

Posted on 2013-01-29
3
Medium Priority
?
137 Views
Last Modified: 2013-01-30
There is a stored proc in DB1 (SQL 2000) that deletes and inserts into a table in another database (DB2) in the same server.

But now the other database (DB2) had to be moved to another SQL 2008 server and henee linked server was created.

but now the sp fails.. because LS only reads.. no other permissions..

i thoughts about 'execute as', but that is not available in sql 2000..

what would recommend as the best practise to just give just enough permission to be able to do the del/insert into the other database.
0
Comment
Question by:25112
  • 2
3 Comments
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 2000 total points
ID: 38831655
Seems like a permission issue to me, you can try creating the linked server using a the SQL login which has permission to delete on SQL 2008 Server.
0
 
LVL 5

Author Comment

by:25112
ID: 38832162
thanks.. i find that the linked server login did not have those permission..

now, i have a touble with this solution..

the linked server (destination) DB2 is being linked to many servers including DB1.. all the servers use the same readonly login (DataConnect_Login) to the DB2 database. Only this proc in one app needs more than read..

do you have any suggestion to keep this clean (in the above scenario)..

If DataConnect_Login is given update and delete on this login for this proc, then all servers have update/del permission on this table.. rather only DB1 needs this feature. (the idea is not to give DataConnect_Login more than read, but also keep it simple.. I am open to ideas.. if there is no other way, then will revert to the first option)

Is there any out of the box idea  beside the above?

thanks
0
 
LVL 75

Expert Comment

by:Aneesh Retnakaran
ID: 38835832
>do you have any suggestion to keep this clean (in the above scenario)..
SPN will be your best shot, if you setup the SPNs you dont have to specify explicit SQL logins
Google for SQL SPN, its pretty simple to setup
0

Featured Post

Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

886 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question