562 attributed reviews in the last 3 years
Refreshingly small course sizes
Outstandingly good courseware
Whizzy online classrooms
Wise Owls only (no freelancers)
Almost no cancellations
We have genuine integrity
We invoice after training
Review 30+ years of Wise Owl
View our top 100 clients
How to get data from tabular models using DAX queries in various programs
Part two of a six-part series of blogs
Knowing how to write DAX queries is one thing, but where are you going to use them? This blog shows how you can integrate DAX queries into SSMS, SSRS, SSIS, Excel and PowerPivot.
So you've deployed a tabular model. How can you write DAX queries to get information out of it within SSMS (SQL Server Management Studio)?
I've already mentioned this in my previous blog on how to write DAX queries, but thought it would be useful to explain this in more detail here.
The first thing to do is to make sure you're using your Analysis Services database, by connecting to it:
Choose to connect to Analysis Services.
Now list your databases, and choose to create a new query in the model of interest:
Choose this option (even though you actually want to create a query in DAX, not MDX).
From now on, you're on your own! You can type in your DAX query, but you'll need to get the syntax right:
Here I'm summarising total sales by species.
Note that you can't drag columns in from the cube on the left, since SSMS will assume that you're writing MDX and use MDX format, not DAX, to type in the column names.
When you've finished writing your query, you can execute it to see the results as shown above:
Click on the usual button to run your query.
Next up - including DAX queries within SSRS reports.
|Parts of this blog|
25 Aytoun Street