Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!View all the Fabric Data Days sessions on demand. View schedule
How do I calculate a metric which is the following for the last month.
What I have does not work:
this table 'time to conversion is connected to 'dim_date[Date]
% one session conversions =
CALCULATE(
COUNT('time_to conversion'[user_pseudo_id]),
'time_to conversion'[Session To Conversion Band] = "1"
)
/ DISTINCTCOUNT('time_to conversion'[user_pseudo_id])
Solved! Go to Solution.
Hello, @Anonymous ,
it depends on how you define last month but, if you have a calendar with some flag or just have Slicer.
you can do something like this.
% one session conversions =
CALCULATE(
CALCULATE(
COUNT('time_to conversion'[user_pseudo_id]),
'time_to conversion'[Session To Conversion Band] = "1"
)
/ DISTINCTCOUNT('time_to conversion'[user_pseudo_id]),
'calendar'[YearMonth]=MAX('calendar'[YearMonth])
)
alternatively using TOTALMTD
% one session conversions =
TOTALMTD(CALCULATE(
COUNT('time_to conversion'[user_pseudo_id]),
'time_to conversion'[Session To Conversion Band] = "1"
)
/ DISTINCTCOUNT('time_to conversion'[user_pseudo_id]), 'calendar'[Date])or datesmtd
% one session conversions =
CALCULATE(
CALCULATE(
COUNT('time_to conversion'[user_pseudo_id]),
'time_to conversion'[Session To Conversion Band] = "1"
)
/ DISTINCTCOUNT('time_to conversion'[user_pseudo_id]),
DATESMTD('calendar'[Date]) )
Hello, @Anonymous ,
it depends on how you define last month but, if you have a calendar with some flag or just have Slicer.
you can do something like this.
% one session conversions =
CALCULATE(
CALCULATE(
COUNT('time_to conversion'[user_pseudo_id]),
'time_to conversion'[Session To Conversion Band] = "1"
)
/ DISTINCTCOUNT('time_to conversion'[user_pseudo_id]),
'calendar'[YearMonth]=MAX('calendar'[YearMonth])
)
alternatively using TOTALMTD
% one session conversions =
TOTALMTD(CALCULATE(
COUNT('time_to conversion'[user_pseudo_id]),
'time_to conversion'[Session To Conversion Band] = "1"
)
/ DISTINCTCOUNT('time_to conversion'[user_pseudo_id]), 'calendar'[Date])or datesmtd
% one session conversions =
CALCULATE(
CALCULATE(
COUNT('time_to conversion'[user_pseudo_id]),
'time_to conversion'[Session To Conversion Band] = "1"
)
/ DISTINCTCOUNT('time_to conversion'[user_pseudo_id]),
DATESMTD('calendar'[Date]) )
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!