Re: Facing the same problem
- From: axneon@xxxxxxxxxxxxxx
- Date: Tue, 12 Aug 2008 09:16:20 -0700 (PDT)
On Aug 11, 5:23 pm, Erland Sommarskog <esq...@xxxxxxxxxxxxx> wrote:
(axn...@xxxxxxxxxxxxxx) writes:
I am facing the same (well, similar) issue as the OP. Here's the
scenario. My stored procedure is being activated from a Service Broker
queue. Within the stored procedure, it is trying to do some operations
across a Linked server, which is failing with the15274(Access to the
remote server is denied because the current security context is not
trusted.) error.
The linked server is a SQL server, but not one where I have any
control. The username & password for connecting to the linked server
were provided to us by another team, so we have to use that only.
What is the solution to this problem (does a solution even exist??!)
Needless to say, the procedure works when executed from an interactive
session.
Have you tried making the database trustworthy?
ALTER DATABASE db SET TRUSTWORTHY
A broker-activation procedure runs in an impersonated context, and when
you impersonate a database user, you get locked into a sandbox if the
database is not marked as trustworthy.
Marking a database as trustworthy where you own all databases is not
a big issue. But if you are not the DBA, but only the database owner,
the DBA may (well he should) be reluctant to make the database trust-
worthy.
--
Erland Sommarskog, SQL Server MVP, esq...@xxxxxxxxxxxxx
Links for SQL Server Books Online:
SQL 2008:http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx
SQL 2005:http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx
SQL 2000:http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Wow! That worked like a charm. Thanks a bunch.
.
- References:
- Facing the same problem
- From: axneon
- Re: Facing the same problem
- From: Erland Sommarskog
- Facing the same problem
- Prev by Date: SQL server connection error
- Next by Date: Re: Blocking Access Reporting
- Previous by thread: Re: Facing the same problem
- Next by thread: SQL server connection error
- Index(es):
Relevant Pages
|