dbTalk Databases Forums  

Connecting to local cube created from AS 2000 and AS 2005 cubes using ADOMD.NET 9.0

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Connecting to local cube created from AS 2000 and AS 2005 cubes using ADOMD.NET 9.0 in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
aabdel1@gmail.com
 
Posts: n/a

Default Connecting to local cube created from AS 2000 and AS 2005 cubes using ADOMD.NET 9.0 - 09-13-2006 , 08:46 AM






Hello,

I created two local cubes, first one: from an AS 2000 cube and the
second one from an AS 2005 cube. Then I tried to connect to them using
the following code:

' AS 2000
Dim strDataSource As String = "MyFolderPath\AS2000LocalCube.cub"
Dim strDatabase As String = "AS2000LocalCubeName"


' AS 20005
'Dim strDataSource As String = "MyFolderPath\AS2005LocalCube.cub"
'Dim strDatabase As String = "AS2005LocalCubeName"

strConnectString = "Provider=MSOLAP;Data Source=" & strDataSource &
";Catalog=" & strDatabase & ";MDX Compatibility=2;"
Dim clConnection As New AdomdConnection
clConnection.ConnectionString = strConnectString
clConnection.Open()


It works properly for AS 2000 local cube but for AS 20005 local cube,
it return the following exception:
InnerException {"The 'MyFolderPath\AS2005LocalCube.cub' local cube
file cannot be opened."} System.Exception

Message "A connection cannot be made. Ensure that the server is
running." String

Source "Microsoft.AnalysisServices.AdomdClient" String

StackTrace " at
Microsoft.AnalysisServices.AdomdClient.XmlaClient. Connect(ConnectionInfo
connectionInfo, Boolean beginSession)
at
Microsoft.AnalysisServices.AdomdClient.AdomdConnec tion.XmlaClientProvider.Microsoft.AnalysisServices .AdomdClient.AdomdConnection.IXmlaClientProviderEx .ConnectXmla()
at
Microsoft.AnalysisServices.AdomdClient.AdomdConnec tion.ConnectToXMLA(Boolean
createSession, Boolean isHTTP)
at Microsoft.AnalysisServices.AdomdClient.AdomdConnec tion.Open()

Both local cubes were created using the same MDX query.

Abdel


Reply With Quote
  #2  
Old   
Ken Kwok [MS]
 
Posts: n/a

Default Re: Connecting to local cube created from AS 2000 and AS 2005 cubes using ADOMD.NET 9.0 - 09-20-2006 , 11:19 PM






Try to use full path of your local cube file. Also, use MSOLAP.3 in 2005 if
possible.

--
This posting is provided "AS IS" with no warranties, and confers no rights.

Ken Kwok
SQL Server Analysis Services

<aabdel1 (AT) gmail (DOT) com> wrote

Quote:
Hello,

I created two local cubes, first one: from an AS 2000 cube and the
second one from an AS 2005 cube. Then I tried to connect to them using
the following code:

' AS 2000
Dim strDataSource As String = "MyFolderPath\AS2000LocalCube.cub"
Dim strDatabase As String = "AS2000LocalCubeName"


' AS 20005
'Dim strDataSource As String = "MyFolderPath\AS2005LocalCube.cub"
'Dim strDatabase As String = "AS2005LocalCubeName"

strConnectString = "Provider=MSOLAP;Data Source=" & strDataSource &
";Catalog=" & strDatabase & ";MDX Compatibility=2;"
Dim clConnection As New AdomdConnection
clConnection.ConnectionString = strConnectString
clConnection.Open()


It works properly for AS 2000 local cube but for AS 20005 local cube,
it return the following exception:
InnerException {"The 'MyFolderPath\AS2005LocalCube.cub' local cube
file cannot be opened."} System.Exception

Message "A connection cannot be made. Ensure that the server is
running." String

Source "Microsoft.AnalysisServices.AdomdClient" String

StackTrace " at
Microsoft.AnalysisServices.AdomdClient.XmlaClient. Connect(ConnectionInfo
connectionInfo, Boolean beginSession)
at
Microsoft.AnalysisServices.AdomdClient.AdomdConnec tion.XmlaClientProvider.Microsoft.AnalysisServices .AdomdClient.AdomdConnection.IXmlaClientProviderEx .ConnectXmla()
at
Microsoft.AnalysisServices.AdomdClient.AdomdConnec tion.ConnectToXMLA(Boolean
createSession, Boolean isHTTP)
at Microsoft.AnalysisServices.AdomdClient.AdomdConnec tion.Open()

Both local cubes were created using the same MDX query.

Abdel




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.