Hello,
I'm working with services in separate dbs on the same SQL2005 instance.
When trying to send a message from one service to the other, it fails with a
security context error (916).
The context of the user in the originating db is a dbo. What is the minimum
access required for the user on the targetDB?
Here's the code:
declare @serviceBrokerId nvarchar(128)
declare @dbName varchar(128)
SELECT @dbName = 'targetDB'
SELECT @serviceBrokerId = service_broker_guid
FROM sys.databases
WHERE name = @dbName
DECLARE @conversationHandle UNIQUEIDENTIFIER ;
BEGIN DIALOG CONVERSATION @conversationHandle
FROM SERVICE DBInboundIntegrationPipelineInitiatorService
TO SERVICE 'NexusInboundService', @serviceBrokerId
WITH ENCRYPTION = OFF;
-- Send the message on the dialog.
SEND ON CONVERSATION @conversationHandle
(@msg) ;
The DBInboundIntegrationPipelineInitiatorService executes as "SELF"
Thanks,
KH
Kevin Horner - 21 Aug 2008 18:04 GMT
Never mind...RTFM...
My initiator DB was not set to TRUSTWORTHY
> Hello,
>
[quoted text clipped - 28 lines]
> Thanks,
> KH