Mangesh Tambare
Mangesh Tambare

Reputation: 59

Error message from database execution: Access to the remote server is denied because no login-mapping exists

Environment & Details

Problem

It is throwing an error – Database operation failed on server 'Server name' with SQL Error Number '7416'. Error message from database execution: Access to the remote server is denied because no login-mapping exists.

Any solutions?

Upvotes: 1

Views: 5992

Answers (1)

Avitus
Avitus

Reputation: 15968

You need to Add “User ID=Username” into the provider string on your linked server when it's created.

EXEC master.dbo.sp_addlinkedserver @server = N’LinkServerName’, @provider=N’SQLNCLI’,@srvproduct = ‘MS SQL Server’, @provstr=N’SERVER=serverName\InstanceName;User ID=myUser‘ 

you can read more here: https://blogs.technet.microsoft.com/mdegre/2011/03/10/access-to-the-remote-server-is-denied-because-no-login-mapping-exists/

Upvotes: 1

Related Questions