Product dimension integration

The SQL view for the product dimension referenced earlier in this chapter contained the following four operations:

  1. Join the Product, ProductSubcategory, and ProductCategory dimension tables into a single query
  2. Create a custom product category group column (for example, Bikes versus Non-Bikes)
  3. Apply report-friendly column names with spaces and proper casing
  4. Replace any null values in the Product Subcategory and Product Category columns with the 'Undefined' value

Like almost all operations available to SQL SELECT queries, the same query can also be created via M functions. If the SQL view for the product dimension cannot be created within the data source, the following M query produces the same results:

let

Get Microsoft Power BI Complete Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.