Forum Discussion

arhomberg's avatar
arhomberg
Helper I
3 years ago
Solved

Calculated Column with Date Limits

Hello all,   I am attempting to create a calculated column that does a distinct count within another table. I have a subscriptions table that holds a customer id and a start and end date. There is ...
  • arhomberg's avatar
    3 years ago

    I was able to solve this with the following:

     

  • ChrisMendoza's avatar
    3 years ago

    arhomberg - This seems to work:

    Column =
    SUMMARIZE (
        FILTER (
            Usage,
            Usage[customer_id] = Subscriptions[customer_id]
                && Usage[date] >= Subscriptions[start_date]
                && Usage[date] <= Subscriptions[end_date]
        ),
        "@", DISTINCTCOUNT ( Usage[user_id] )
    )