SlideShare a Scribd company logo
1 of 23
Download to read offline
Unlocking the
Mystery of MDX
            Bryan Smith
    brysmi@microsoft.com
Objectives
                 Obj ti
Explain h d behind
E l i the modell b hi d MDX
        Explore lessons learned
The i
Th views and opinions expressed in this ....
           d ii               d i thi
(3)


                                              x
-4   -3   -2   -1   0   1   2   3         4
y




                4
                                     (3, 2)




                3
                2
                1
                                              x
-4   -3   -2   -1        1   2   3    4

                -2
                -3
                -4
y




                4
                                     (3, 2, 4)




                3
                2
                1
                                                 x
-4   -3   -2   -1        1   2   3       4

                -2
z
                -3
                -4
one-dimensional           (x)               single




two-dimensional            (x, y)           double




three-dimensionall
 h di i                     (x, )
                            ( y, z)         triple
                                              il



                     (a1, a2, a3, a4)
four-dimensional             (x, y, z, ?)   quadruple
four-dimensional
f di i l                   (a
                           ( 1 , a2 , a3 , a4 )        quadruple
                                                          d l

five-dimensional    (a1, a2, a3, a4, a5)               quintuple

six-dimensional     (a1, a2, a3, a4, a5, a6)           sextuple

seven-dimensional   (a1, a2, a3, a4, a5, a6, a7)       septuple

eight dimensional
eight-dimensional   (a1, a2, a3, a4, a5, a6, a7, a8)   octuple
four-dimensional
four dimensional           (a1, a2, a3, a4)            quadruple

five-dimensional    (a1, a2, a3, a4, a5)               quintuple

six-dimensional     (a1, a2, a3, a4, a5, a6)           sextuple

seven-dimensional   (a1, a2, a3, a4, a5, a6, a7)       septuple

eight dimensional
eight-dimensional   (a1, a2, a3, a4, a5, a6, a7, a8)   octuple




n-dimensional       (a1, a2, … an)                     tuple
My Simple Cube


      Measure Group

       Σ   Measure


      Dimension

           Attribute
My Simple Cube


    Reseller Sales                       Internet Sales

6    Σ Reseller Sales Amount              Σ Internet Sales Amount

    Date                       Product                       Geography
     1 Fiscal Year              3 Category                     5 Country

     2 Calendar Year            4 Subcategory
Product
P d t
     Category


                          All Products



    Accessories   Bikes                  Clothing   Components
Components
                                                 C
                     ([Bikes])




                                               Clo
                                                 othing
                                               Bike
                                                  es
                                                Accessories
                                                A
                                                Alll Products
          Category



                        [Product].[Category]
P d t
Product
(                                           (
     a1,
     [CY 2002],                              [Date].[Calendar Year].[CY 2002],
     [All Periods],
     a2,                                     [Date].[Fiscal Year].[All Periods],
     [Bikes],
     a3,                                     [Product].[Category].[Bikes],
     [All Products],
     a4,                                     [Product].[Subcategory].[All Products],
     [All Geographies],
     a5,                                     [Geography].[Country].[All Geographies],
     [Reseller Sales Amount]
     a6                                      [Measures].[Reseller Sales Amount]
    )                                       )


(
 [Geography].[Country].[All Geographies],
 [Product].[Category].[Bikes],
 [Measures].[Reseller Sales Amount],
 [ ][
 [Date].[Fiscal Year].[All Periods],
                    ][            ]
 [Product].[Subcategory].[All Products],
 [Date].[Calendar Year].[CY 2002]
)
(
(                                                                              [Date].[Calendar Year].[CY 2002],
    [Date].[Calendar Y ] [CY
    [D ] [C l d Year].[CY 2002], ]                                             [ ][
                                                                               [Date].[Fiscal Year].[All Periods],
                                                                                                  ][            ],
    [Product].[Category].[Bikes]                                               [Product].[Category].[Bikes]
)                                                                              [Product].[Subcategory].[All Products],
                                                                               [Geography].[Country].[All Geographies],
                                                                               [Measures].[Reseller Sales Amount]
                                                                           )




     Attributes                      Partial   Rule 1                  Rule 2                      Rule 3                 Completed
                                     Tuple     Default Member          (All) Member                First Member           Tuple

     Date.Calendar Year              CY 2002                                                                              CY 2002
     Date.Fiscal Year                                                  All Periods                                        All Periods
     Product.Category                Bikes                                                                                Bikes
     Product.Subcategory                                               All Products                                       All Products
     Geography.Country                                                 All Geographies                                    All Geographies
     Measures                                  Reseller Sales Amount                                                      Reseller Sales Amount
SELECT
     [Date].[Calendar Year].Members ON COLUMNS,
     [Product].[Category].Members ON ROWS
   FROM [My Simple Cube]




                                 All Periods       CY 2001       CY 2002       CY 2003       CY 2004
All Products                     $80,450,597      $8,065,435   $24,144,430   $32,202,669   $16,038,063
Accessories                        $571,298         $20,235       $92,735      $296,533      $161,794
Bikes                            $66,302,382      $7,395,349   $19,956,015   $25,551,775   $13,399,243
Clothing                          $1,777,840        $34,376      $485,587      $871,864      $386,013
Components                       $11,799,077        $34,376     $3,610,092    $5,482,497    $2,091,012
MDX
      SELECT
        [Date].[Calendar Y ] M b
        [D ] [C l d Year].Members ON COLUMNS,
                                         COLUMNS
        [Product].[Category].Members ON ROWS
      FROM [My Simple Cube]




SQL
      SELECT
        e.CalendarYear,
        d.EnglishProductCategoryName,
        SUM(a.SalesAmount)
      FROM FactResellerSales a
      INNER JOIN DimProduct b
        ON a.ProductKey=b.ProductKey
                 d       b d
      INNER JOIN DimProductSubcategory c
        ON b.ProductSubcategoryKey=c.ProductSubcategoryKey
      INNER JOIN DimProductCategory d
        ON c.ProductCategoryKey=d.ProductCategoryKey
      INNER JOIN DimDate e
        ON a.OrderDateKey=e.DateKey
      GROUP BY
        e.CalendarYear,
        d.EnglishProductCategoryName
MDX
      WITH MEMBER [Measures].[Total Sales Amount] AS
        [Measures].[Internet Sales Amount] + [Measures].[Reseller Sales Amount]
        [M       ] [I        Sl A         ] [M         ] [R ll S l A          ]
      SET [Top 10 Products of 2003] AS
        TOPCOUNT(
            [Product].[Product].[Product].Members, 10,
            ([Measures].[Total Sales Amount], [Date].[Calendar Year].[CY 2003])
            )
      SELECT
        [Measures].[Total Sales Amount] ON COLUMNS,
        [Top 10 Products of 2003] ON ROWS
      FROM [Step-by-Step]
      WHERE ([Date].[Calendar Year].[CY 2004])

SQL
      SELECT
        m.EnglishProductName,
        o.TotalSalesAmount
      FROM dbo.DimProduct m
      INNER JOIN ( -- TOP 10 PRODUCTS OF 2003
        SELECT TOP 10
           a.ProductKey, SUM(a.SalesAmount) AS TotalSalesAmount
                 d             ( l        )        l l
        FROM (
           SELECT
              x.productkey, x.salesamount
           FROM dbo.FactInternetSales x
           INNER JOIN dbo.DimDate y
              ON x.OrderDateKey=y.DateKey
           WHERE y.CalendarYear=2003
           UNION ALL
           SELECT
              x.productkey, x.salesamount
Lessons Learned
         L       L     d
        Clearly d fi
        Cl l define audience
                         di
Align technology with audience
       Actively engage audience
Thank You!
brysmi@microsoft.com

More Related Content

Viewers also liked

Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)
Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)
Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)Daniel Upton
 
Citrix MDX Technologies Feature Brief
Citrix MDX Technologies Feature BriefCitrix MDX Technologies Feature Brief
Citrix MDX Technologies Feature BriefNuno Alves
 
Ssis sql ssrs_sp_ssas_mdx_hb_li
Ssis sql ssrs_sp_ssas_mdx_hb_liSsis sql ssrs_sp_ssas_mdx_hb_li
Ssis sql ssrs_sp_ssas_mdx_hb_liHong-Bing Li
 
SQL Server Analysis Services and MDX
SQL Server Analysis Services and MDXSQL Server Analysis Services and MDX
SQL Server Analysis Services and MDXMark Ginnebaugh
 
Mdx university dubai courses
Mdx university dubai coursesMdx university dubai courses
Mdx university dubai coursesanjam tm
 
Multidimensional expressions mdx - reference
Multidimensional expressions   mdx - referenceMultidimensional expressions   mdx - reference
Multidimensional expressions mdx - referenceSteve Xu
 
Business Intelligence Portfolio
Business Intelligence PortfolioBusiness Intelligence Portfolio
Business Intelligence PortfolioDoug Armantrout
 
2012 Acura MDX Brochure | DCH Acura of Temecula
2012 Acura MDX Brochure | DCH Acura of Temecula2012 Acura MDX Brochure | DCH Acura of Temecula
2012 Acura MDX Brochure | DCH Acura of TemeculaDCH Acura of Temecula
 
IBM Cognos Dimensional Dashboarding Techniques
IBM Cognos Dimensional Dashboarding TechniquesIBM Cognos Dimensional Dashboarding Techniques
IBM Cognos Dimensional Dashboarding TechniquesSenturus
 
rmoore.smartquery KScope15
rmoore.smartquery KScope15rmoore.smartquery KScope15
rmoore.smartquery KScope15Ron Moore
 
Moore Advanced Calculations in Calc Manager OW 20151015
Moore Advanced Calculations in Calc Manager  OW 20151015Moore Advanced Calculations in Calc Manager  OW 20151015
Moore Advanced Calculations in Calc Manager OW 20151015Ron Moore
 
MDX (Multi Dimensional Expressions) Introduction
MDX (Multi Dimensional Expressions) IntroductionMDX (Multi Dimensional Expressions) Introduction
MDX (Multi Dimensional Expressions) IntroductionDigvendra Singh
 
Ssis sql ssrs_ssas_sp_mdx_hb_li
Ssis sql ssrs_ssas_sp_mdx_hb_liSsis sql ssrs_ssas_sp_mdx_hb_li
Ssis sql ssrs_ssas_sp_mdx_hb_liHong-Bing Li
 
Big Data MDX with Mondrian and Apache Kylin
Big Data MDX with Mondrian and Apache KylinBig Data MDX with Mondrian and Apache Kylin
Big Data MDX with Mondrian and Apache Kylininovex GmbH
 
Essbase Calculations A Visual Approach KScope 2010
Essbase Calculations A Visual Approach KScope 2010Essbase Calculations A Visual Approach KScope 2010
Essbase Calculations A Visual Approach KScope 2010Ron Moore
 

Viewers also liked (20)

Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)
Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)
Enhancing Dashboard Visuals with Multi-Dimensional Expressions (MDX)
 
Citrix MDX Technologies Feature Brief
Citrix MDX Technologies Feature BriefCitrix MDX Technologies Feature Brief
Citrix MDX Technologies Feature Brief
 
Introduction to mdx query ppt
Introduction to mdx query pptIntroduction to mdx query ppt
Introduction to mdx query ppt
 
Ssis sql ssrs_sp_ssas_mdx_hb_li
Ssis sql ssrs_sp_ssas_mdx_hb_liSsis sql ssrs_sp_ssas_mdx_hb_li
Ssis sql ssrs_sp_ssas_mdx_hb_li
 
Mdx complex-queries-130019
Mdx complex-queries-130019Mdx complex-queries-130019
Mdx complex-queries-130019
 
SQL Server Analysis Services and MDX
SQL Server Analysis Services and MDXSQL Server Analysis Services and MDX
SQL Server Analysis Services and MDX
 
Mdx university dubai courses
Mdx university dubai coursesMdx university dubai courses
Mdx university dubai courses
 
Multidimensional expressions mdx - reference
Multidimensional expressions   mdx - referenceMultidimensional expressions   mdx - reference
Multidimensional expressions mdx - reference
 
Business Intelligence Portfolio
Business Intelligence PortfolioBusiness Intelligence Portfolio
Business Intelligence Portfolio
 
2012 Acura MDX Brochure | DCH Acura of Temecula
2012 Acura MDX Brochure | DCH Acura of Temecula2012 Acura MDX Brochure | DCH Acura of Temecula
2012 Acura MDX Brochure | DCH Acura of Temecula
 
IBM Cognos Dimensional Dashboarding Techniques
IBM Cognos Dimensional Dashboarding TechniquesIBM Cognos Dimensional Dashboarding Techniques
IBM Cognos Dimensional Dashboarding Techniques
 
MDX 2015-2019 Work Program Overview presentation, October 22, 2014
MDX 2015-2019 Work Program Overview presentation, October 22, 2014MDX 2015-2019 Work Program Overview presentation, October 22, 2014
MDX 2015-2019 Work Program Overview presentation, October 22, 2014
 
rmoore.smartquery KScope15
rmoore.smartquery KScope15rmoore.smartquery KScope15
rmoore.smartquery KScope15
 
Moore Advanced Calculations in Calc Manager OW 20151015
Moore Advanced Calculations in Calc Manager  OW 20151015Moore Advanced Calculations in Calc Manager  OW 20151015
Moore Advanced Calculations in Calc Manager OW 20151015
 
MDX (Multi Dimensional Expressions) Introduction
MDX (Multi Dimensional Expressions) IntroductionMDX (Multi Dimensional Expressions) Introduction
MDX (Multi Dimensional Expressions) Introduction
 
Ssis sql ssrs_ssas_sp_mdx_hb_li
Ssis sql ssrs_ssas_sp_mdx_hb_liSsis sql ssrs_ssas_sp_mdx_hb_li
Ssis sql ssrs_ssas_sp_mdx_hb_li
 
SSRS for DBA's
SSRS for DBA'sSSRS for DBA's
SSRS for DBA's
 
Big Data MDX with Mondrian and Apache Kylin
Big Data MDX with Mondrian and Apache KylinBig Data MDX with Mondrian and Apache Kylin
Big Data MDX with Mondrian and Apache Kylin
 
Essbase Calculations A Visual Approach KScope 2010
Essbase Calculations A Visual Approach KScope 2010Essbase Calculations A Visual Approach KScope 2010
Essbase Calculations A Visual Approach KScope 2010
 
SSAS and MDX
SSAS and MDXSSAS and MDX
SSAS and MDX
 

More from DATAVERSITY

Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...
Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...
Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...DATAVERSITY
 
Data at the Speed of Business with Data Mastering and Governance
Data at the Speed of Business with Data Mastering and GovernanceData at the Speed of Business with Data Mastering and Governance
Data at the Speed of Business with Data Mastering and GovernanceDATAVERSITY
 
Exploring Levels of Data Literacy
Exploring Levels of Data LiteracyExploring Levels of Data Literacy
Exploring Levels of Data LiteracyDATAVERSITY
 
Building a Data Strategy – Practical Steps for Aligning with Business Goals
Building a Data Strategy – Practical Steps for Aligning with Business GoalsBuilding a Data Strategy – Practical Steps for Aligning with Business Goals
Building a Data Strategy – Practical Steps for Aligning with Business GoalsDATAVERSITY
 
Make Data Work for You
Make Data Work for YouMake Data Work for You
Make Data Work for YouDATAVERSITY
 
Data Catalogs Are the Answer – What is the Question?
Data Catalogs Are the Answer – What is the Question?Data Catalogs Are the Answer – What is the Question?
Data Catalogs Are the Answer – What is the Question?DATAVERSITY
 
Data Catalogs Are the Answer – What Is the Question?
Data Catalogs Are the Answer – What Is the Question?Data Catalogs Are the Answer – What Is the Question?
Data Catalogs Are the Answer – What Is the Question?DATAVERSITY
 
Data Modeling Fundamentals
Data Modeling FundamentalsData Modeling Fundamentals
Data Modeling FundamentalsDATAVERSITY
 
Showing ROI for Your Analytic Project
Showing ROI for Your Analytic ProjectShowing ROI for Your Analytic Project
Showing ROI for Your Analytic ProjectDATAVERSITY
 
How a Semantic Layer Makes Data Mesh Work at Scale
How a Semantic Layer Makes  Data Mesh Work at ScaleHow a Semantic Layer Makes  Data Mesh Work at Scale
How a Semantic Layer Makes Data Mesh Work at ScaleDATAVERSITY
 
Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?DATAVERSITY
 
The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...
The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...
The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...DATAVERSITY
 
Emerging Trends in Data Architecture – What’s the Next Big Thing?
Emerging Trends in Data Architecture – What’s the Next Big Thing?Emerging Trends in Data Architecture – What’s the Next Big Thing?
Emerging Trends in Data Architecture – What’s the Next Big Thing?DATAVERSITY
 
Data Governance Trends - A Look Backwards and Forwards
Data Governance Trends - A Look Backwards and ForwardsData Governance Trends - A Look Backwards and Forwards
Data Governance Trends - A Look Backwards and ForwardsDATAVERSITY
 
Data Governance Trends and Best Practices To Implement Today
Data Governance Trends and Best Practices To Implement TodayData Governance Trends and Best Practices To Implement Today
Data Governance Trends and Best Practices To Implement TodayDATAVERSITY
 
2023 Trends in Enterprise Analytics
2023 Trends in Enterprise Analytics2023 Trends in Enterprise Analytics
2023 Trends in Enterprise AnalyticsDATAVERSITY
 
Data Strategy Best Practices
Data Strategy Best PracticesData Strategy Best Practices
Data Strategy Best PracticesDATAVERSITY
 
Who Should Own Data Governance – IT or Business?
Who Should Own Data Governance – IT or Business?Who Should Own Data Governance – IT or Business?
Who Should Own Data Governance – IT or Business?DATAVERSITY
 
Data Management Best Practices
Data Management Best PracticesData Management Best Practices
Data Management Best PracticesDATAVERSITY
 
MLOps – Applying DevOps to Competitive Advantage
MLOps – Applying DevOps to Competitive AdvantageMLOps – Applying DevOps to Competitive Advantage
MLOps – Applying DevOps to Competitive AdvantageDATAVERSITY
 

More from DATAVERSITY (20)

Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...
Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...
Architecture, Products, and Total Cost of Ownership of the Leading Machine Le...
 
Data at the Speed of Business with Data Mastering and Governance
Data at the Speed of Business with Data Mastering and GovernanceData at the Speed of Business with Data Mastering and Governance
Data at the Speed of Business with Data Mastering and Governance
 
Exploring Levels of Data Literacy
Exploring Levels of Data LiteracyExploring Levels of Data Literacy
Exploring Levels of Data Literacy
 
Building a Data Strategy – Practical Steps for Aligning with Business Goals
Building a Data Strategy – Practical Steps for Aligning with Business GoalsBuilding a Data Strategy – Practical Steps for Aligning with Business Goals
Building a Data Strategy – Practical Steps for Aligning with Business Goals
 
Make Data Work for You
Make Data Work for YouMake Data Work for You
Make Data Work for You
 
Data Catalogs Are the Answer – What is the Question?
Data Catalogs Are the Answer – What is the Question?Data Catalogs Are the Answer – What is the Question?
Data Catalogs Are the Answer – What is the Question?
 
Data Catalogs Are the Answer – What Is the Question?
Data Catalogs Are the Answer – What Is the Question?Data Catalogs Are the Answer – What Is the Question?
Data Catalogs Are the Answer – What Is the Question?
 
Data Modeling Fundamentals
Data Modeling FundamentalsData Modeling Fundamentals
Data Modeling Fundamentals
 
Showing ROI for Your Analytic Project
Showing ROI for Your Analytic ProjectShowing ROI for Your Analytic Project
Showing ROI for Your Analytic Project
 
How a Semantic Layer Makes Data Mesh Work at Scale
How a Semantic Layer Makes  Data Mesh Work at ScaleHow a Semantic Layer Makes  Data Mesh Work at Scale
How a Semantic Layer Makes Data Mesh Work at Scale
 
Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?Is Enterprise Data Literacy Possible?
Is Enterprise Data Literacy Possible?
 
The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...
The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...
The Data Trifecta – Privacy, Security & Governance Race from Reactivity to Re...
 
Emerging Trends in Data Architecture – What’s the Next Big Thing?
Emerging Trends in Data Architecture – What’s the Next Big Thing?Emerging Trends in Data Architecture – What’s the Next Big Thing?
Emerging Trends in Data Architecture – What’s the Next Big Thing?
 
Data Governance Trends - A Look Backwards and Forwards
Data Governance Trends - A Look Backwards and ForwardsData Governance Trends - A Look Backwards and Forwards
Data Governance Trends - A Look Backwards and Forwards
 
Data Governance Trends and Best Practices To Implement Today
Data Governance Trends and Best Practices To Implement TodayData Governance Trends and Best Practices To Implement Today
Data Governance Trends and Best Practices To Implement Today
 
2023 Trends in Enterprise Analytics
2023 Trends in Enterprise Analytics2023 Trends in Enterprise Analytics
2023 Trends in Enterprise Analytics
 
Data Strategy Best Practices
Data Strategy Best PracticesData Strategy Best Practices
Data Strategy Best Practices
 
Who Should Own Data Governance – IT or Business?
Who Should Own Data Governance – IT or Business?Who Should Own Data Governance – IT or Business?
Who Should Own Data Governance – IT or Business?
 
Data Management Best Practices
Data Management Best PracticesData Management Best Practices
Data Management Best Practices
 
MLOps – Applying DevOps to Competitive Advantage
MLOps – Applying DevOps to Competitive AdvantageMLOps – Applying DevOps to Competitive Advantage
MLOps – Applying DevOps to Competitive Advantage
 

Recently uploaded

Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Principled Technologies
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024SynarionITSolutions
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 

Recently uploaded (20)

Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 

Unlocking the Mystery of MDX

  • 1. Unlocking the Mystery of MDX Bryan Smith brysmi@microsoft.com
  • 2.
  • 3. Objectives Obj ti Explain h d behind E l i the modell b hi d MDX Explore lessons learned
  • 4. The i Th views and opinions expressed in this .... d ii d i thi
  • 5. (3) x -4 -3 -2 -1 0 1 2 3 4
  • 6. y 4 (3, 2) 3 2 1 x -4 -3 -2 -1 1 2 3 4 -2 -3 -4
  • 7. y 4 (3, 2, 4) 3 2 1 x -4 -3 -2 -1 1 2 3 4 -2 z -3 -4
  • 8. one-dimensional (x) single two-dimensional (x, y) double three-dimensionall h di i (x, ) ( y, z) triple il (a1, a2, a3, a4) four-dimensional (x, y, z, ?) quadruple
  • 9. four-dimensional f di i l (a ( 1 , a2 , a3 , a4 ) quadruple d l five-dimensional (a1, a2, a3, a4, a5) quintuple six-dimensional (a1, a2, a3, a4, a5, a6) sextuple seven-dimensional (a1, a2, a3, a4, a5, a6, a7) septuple eight dimensional eight-dimensional (a1, a2, a3, a4, a5, a6, a7, a8) octuple
  • 10. four-dimensional four dimensional (a1, a2, a3, a4) quadruple five-dimensional (a1, a2, a3, a4, a5) quintuple six-dimensional (a1, a2, a3, a4, a5, a6) sextuple seven-dimensional (a1, a2, a3, a4, a5, a6, a7) septuple eight dimensional eight-dimensional (a1, a2, a3, a4, a5, a6, a7, a8) octuple n-dimensional (a1, a2, … an) tuple
  • 11. My Simple Cube Measure Group Σ Measure Dimension Attribute
  • 12. My Simple Cube Reseller Sales Internet Sales 6 Σ Reseller Sales Amount Σ Internet Sales Amount Date Product Geography 1 Fiscal Year 3 Category 5 Country 2 Calendar Year 4 Subcategory
  • 13. Product P d t Category All Products Accessories Bikes Clothing Components
  • 14. Components C ([Bikes]) Clo othing Bike es Accessories A Alll Products Category [Product].[Category] P d t Product
  • 15. ( ( a1, [CY 2002], [Date].[Calendar Year].[CY 2002], [All Periods], a2, [Date].[Fiscal Year].[All Periods], [Bikes], a3, [Product].[Category].[Bikes], [All Products], a4, [Product].[Subcategory].[All Products], [All Geographies], a5, [Geography].[Country].[All Geographies], [Reseller Sales Amount] a6 [Measures].[Reseller Sales Amount] ) ) ( [Geography].[Country].[All Geographies], [Product].[Category].[Bikes], [Measures].[Reseller Sales Amount], [ ][ [Date].[Fiscal Year].[All Periods], ][ ] [Product].[Subcategory].[All Products], [Date].[Calendar Year].[CY 2002] )
  • 16. ( ( [Date].[Calendar Year].[CY 2002], [Date].[Calendar Y ] [CY [D ] [C l d Year].[CY 2002], ] [ ][ [Date].[Fiscal Year].[All Periods], ][ ], [Product].[Category].[Bikes] [Product].[Category].[Bikes] ) [Product].[Subcategory].[All Products], [Geography].[Country].[All Geographies], [Measures].[Reseller Sales Amount] ) Attributes Partial Rule 1 Rule 2 Rule 3 Completed Tuple Default Member (All) Member First Member Tuple Date.Calendar Year CY 2002 CY 2002 Date.Fiscal Year All Periods All Periods Product.Category Bikes Bikes Product.Subcategory All Products All Products Geography.Country All Geographies All Geographies Measures Reseller Sales Amount Reseller Sales Amount
  • 17. SELECT [Date].[Calendar Year].Members ON COLUMNS, [Product].[Category].Members ON ROWS FROM [My Simple Cube] All Periods CY 2001 CY 2002 CY 2003 CY 2004 All Products $80,450,597 $8,065,435 $24,144,430 $32,202,669 $16,038,063 Accessories $571,298 $20,235 $92,735 $296,533 $161,794 Bikes $66,302,382 $7,395,349 $19,956,015 $25,551,775 $13,399,243 Clothing $1,777,840 $34,376 $485,587 $871,864 $386,013 Components $11,799,077 $34,376 $3,610,092 $5,482,497 $2,091,012
  • 18. MDX SELECT [Date].[Calendar Y ] M b [D ] [C l d Year].Members ON COLUMNS, COLUMNS [Product].[Category].Members ON ROWS FROM [My Simple Cube] SQL SELECT e.CalendarYear, d.EnglishProductCategoryName, SUM(a.SalesAmount) FROM FactResellerSales a INNER JOIN DimProduct b ON a.ProductKey=b.ProductKey d b d INNER JOIN DimProductSubcategory c ON b.ProductSubcategoryKey=c.ProductSubcategoryKey INNER JOIN DimProductCategory d ON c.ProductCategoryKey=d.ProductCategoryKey INNER JOIN DimDate e ON a.OrderDateKey=e.DateKey GROUP BY e.CalendarYear, d.EnglishProductCategoryName
  • 19. MDX WITH MEMBER [Measures].[Total Sales Amount] AS [Measures].[Internet Sales Amount] + [Measures].[Reseller Sales Amount] [M ] [I Sl A ] [M ] [R ll S l A ] SET [Top 10 Products of 2003] AS TOPCOUNT( [Product].[Product].[Product].Members, 10, ([Measures].[Total Sales Amount], [Date].[Calendar Year].[CY 2003]) ) SELECT [Measures].[Total Sales Amount] ON COLUMNS, [Top 10 Products of 2003] ON ROWS FROM [Step-by-Step] WHERE ([Date].[Calendar Year].[CY 2004]) SQL SELECT m.EnglishProductName, o.TotalSalesAmount FROM dbo.DimProduct m INNER JOIN ( -- TOP 10 PRODUCTS OF 2003 SELECT TOP 10 a.ProductKey, SUM(a.SalesAmount) AS TotalSalesAmount d ( l ) l l FROM ( SELECT x.productkey, x.salesamount FROM dbo.FactInternetSales x INNER JOIN dbo.DimDate y ON x.OrderDateKey=y.DateKey WHERE y.CalendarYear=2003 UNION ALL SELECT x.productkey, x.salesamount
  • 20.
  • 21.
  • 22. Lessons Learned L L d Clearly d fi Cl l define audience di Align technology with audience Actively engage audience