Discussion:
CLR Stored procedure fails to connect to Analysis Service 2000
(too old to reply)
m***@gmail.com
2007-09-21 10:07:38 UTC
Permalink
Hi All,

I am to write a CLR stored procedure (Sql Server 2005) which has to
connect to AnalysisService 2000.
But I can't ;)

When I try to connect using the connection string like:
"Provider=msolap;Datasource=abc;Initial Catalog=cde"
i get exception "A connection cannot be made. Ensure that the server
is running."

'cde' is the name of the third database . if i use first one,
everything is Ok.

Additionally, when i try to connect
using :"Provider=msolap;Datasource=abc"
the connection is established, but the command
connectionObject.ChangeDatabase("cde") raises the exception: "Database
'cde' does not exist."
But the command connectionObject.ChangeDatabase("the name of the first
database") is Ok.

The database 'cde' exists for sure. If I use the same connection
strings in WinForm Application everything is ok. I can connect to both
databases.

It looks as if I could connect only to the first database when i try
to do this from clr stored procedure. How to connect to others ?

I will really apreciate any help.

Kind regards
Marcin
m***@gmail.com
2007-09-21 10:38:48 UTC
Permalink
Hi All,

Sorry about a fuss. It's turned out that it's enough to set Database
Roles properly.

Kind regards
Marcin

Loading...