Create a dynamic banding attribute

The goal of this example is to create an attribute on the Customer dimension table that groups the customer into age ranges to support demographic analysis:

  1. Retrieve the current dimension table with the date column to be used for segmentation. The Date of Birth column is the source for this example.
Figure 94: Customer Dimension
  1. Add variables to the let expression to support the comparison between the current system date and the dimension date (Date of Birth).
Figure 95: Current Date Variables
  • DateTime.LocalNow() ...

Get Microsoft Power BI Cookbook 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.