Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MDX syntax in SQL using OPENQUERY

Status
Not open for further replies.

Filia

Programmer
May 13, 2003
3
ZA
I have created a cube in Analysis Server that I am trying to access through the OPENQUERY statement in SQL. The reason for this is that I want to get a flattened rowset from my cube and I have to pass parameters to it through the WHERE clause. Thus I create a stored proc, and within the stored proc I use the OPENQUERY statement to retrieve results. I am getting syntax errors if I try to concatenate the parameters into the OPENQUERY string. Is what I am trying to do possible? I cannot find ANY but the simplest select statements for using MDX in SQL Query Analyser. Can anyne help with useful sites/examples?
Thanks for your help...
 
Hi Filia,

we are doing this in our global Datawarehouse.
The question is, how do you access the OLAP-DB?
You have to link the OLAP-DB as a linked-Server
in SQL-Server. Then you can access the OLAP-Data like
a normal Database with MDX-Statements via OPENQUERY!!

Linked-Server:
You can implement a linked server under "Security" / "Linked Server".
The User you have to give on the Security tab needs a lot of rights on the OLAP-Server. We decided to use a local admin of the OLAP-Server.

If you need more informations please tell!

Christoph
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top