View MDX used in Cube browser - ssas

I am trying to see the MDX which is used in Cube Browser. I searched on google and once again I am being redirected StackOverflow's post View MDX query generated while browsing a cube
Yes, I can see the MDX but when I try to execute the same MDX (copied from Profiler and pasted in SSMS) in SSMS- Analysis server, it does not executes and gives me error.
Am I doing something wrong here? If not, is there any other way to get the MDX out of the cube?
Thanks

Would be helpful to have the error message, but I guess the definition of this set (?) is missing :
select non empty [{73C699C7-F74B-48A7-96AE-E131412D0725}Pivot73Axis0Set0] ...
from your request. Somehow you should have a WITH SET ... in the MDX request as well.

I tried working this out and consulted number of forums but could not get an absolute answer.
But I found a way around for the same using MS EXcel and a plugin http://olappivottableextend.codeplex.com/

you need to include the creation of the set [{73C699C7-F74B-48A7-96AE-E131412D0725}Pivot73Axis0Set0]
It's probably a few line before the code you posted

After making some deep analysis, I have found that SQL Profiler is more awesome tool which helps you to get this query.
What you need to do is Capture all the query between the batch operations and then put them in MDX Query pane in SSMS.
You can execute them one by one and get the result.

A very simple solution:
If you have EXCEL 2010 installed + PowerPivot plugin...
So you open excel 2010 you go to "Powerpivot Icon" you try to open a new connexion ...Then you'll see a window title "MDX STATEMENT" you choose design...
When you finishe designing your cube Y'll see the MDX Statement related...

Related

Unable to see the results section when creating a table in SQL

I'm new to programming and just learning the basics of C# and SQL in Visual Studio Code, so this might be a piece of cake for the pros here :)
I was trying to create and edit a table, but I'm unable to see the results section, I only see the messages part. Tried the suggested ctrl+alt+r but nothing pops up. Just wondering then if it's similar to Visual Studio that has the option to 'Show Table Data' and edit the table.
The results section appears as follows:
and the screenshot from VS (just for reference):
You can use this mssql extension by Microsoft.
Expand the database and right click to the table and choose "Select TOP 1000". Then you should be able to see the results like the image below.
query results

If an existing SSRS report is giving wrong data and I have troubleshoot it...where do I start first?

I have few existing SSRS reports here which are giving some inaccurate info. I want to fix those...where should I start? is it the data source in Report Builder? Where else should I look?
Thanks
You should be able to find the query that is being run or the stored procedure in the datasets. Then you can open those and see what datasource it is using. Some could be shared so you might have to look a bit to find them but that tells you the server. So then you can troubleshoot.

Power-Pivot:500 Internal Server Error

I am importing the ssrs report from .automsvc extension and I am facing the below issue as .Can any one help me how can I solve this issue
Tablix1: The remote server returned an error: (500) Internal Server Error.
If you have any date columns delete them from the SSRS report and see if the PowerPivot connection works. You may need to play with formatting if you want to add the columns back. Trial and error.
Yea, took me a bit to find, but the issue is simple and also stupid. Power Pivot has issues with importing "Calculated Fields" - But I think these are Sharepoint created and might still work with Infopath created Calculated fields, hope this helps someone. Once I removed the calculated fields I stopped getting this error immediately.

How to get current MDX in Tableau?

Given a PivotTable in Tableau, is there a way to know the associated MDX Query?
I would help my understanding current pivot table and fix potential misconstructions.
Unlike ProClarity and some other MDX-generating tools, you can't see the MDX being created while in the UI. However, if you open up the \My Documents\My Tableau Repository\Logs folder, you'll see Desktop's logs. You can open those up and see each and every MDX statement that has been executed against SSAS.
Hope this helps!

view MDX query from SSMS

Any chance I can see the query generated when I'm browsing a cube through SSMS?
I supposed I could run a trace on the DB to capture it, but just wondering if there is an easier way.
Thanks
I am not sure about SSMS (other than trace) but there is an add in for excel which allows you to see the MDX generated on pivot tables. The MDX is sort of similar:
http://olappivottableextend.codeplex.com/
Using the SQL Server Profiler you could see the query generated. Just connect to Analysis Services server and save the trace.