Project Botticelli

MDX Queries Get Free Access Purchase this course

4 December 2013 · 2 comments · 10838 views

The MDX SELECT Statement

Chris Webb introduces a basic MDX SELECT statement

In most cases an MDX SELECT statement is used to retrieve data from a SQL Server Analysis Services cube. Let Chris Webb introduce this important statement to you in this free, 20-minute video. Log-in or get a free account to watch it!

A simple MDX SELECT statement consists of a SELECT clause and a FROM clause. The SELECT clause uses sets to define what appears on rows and columns in a query, while the FROM clause contains the name of the cube that you are querying. The set used on rows cannot contain members from hierarchies that appear in the set on columns, and vice versa. Sets of tuples can be used on any axis to give a nested, or cross-tabbed effect.

A query may also contain a WHERE clause. Unlike in SQL, the WHERE clause doesn’t directly filter what appears on rows or columns, instead it slices the data in your results. You can think of the WHERE clause as an invisible, extra axis that is one tuple deep. When a set is used in the WHERE clause, the results will show aggregated values for all of the members in that set. Rows or columns that only contain null values can be filtered out from your results by adding a NON EMPTY statement before the axis definition in the SELECT clause.

If you would like to learn Multidimensional Expressions with Chris, make sure to watch the remaining videos in our MDX online course, including MDX Basic Concepts and MDX Calculated Members.

Log in or register for free to access this content.

Purchase This Course or Full Access Subscription

Single Course

$250/once

Access this course for its lifetime*.
Purchase
Subscription

$480/year

Access all content on this site for 1 year.
Purchase
Group Purchase

from $480/year

For small business & enterprise.
Group Purchase

  • Redeem a prepaid code
  • Payment is instant and you will receive a tax invoice straight away.
  • Your satisfaction is paramount: we offer a no-quibble refund guarantee.

* We guarantee each course to be available for at least 2 years from today, unless marked above with a date as a Course Retiring.

Comments

joostvk · 8 February 2014

Great explanation, excellent educational skills.

dmayi · 3 October 2014

Excellent! Thanks Chris

Online Courses