Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
karthikponnaih
Frequent Visitor

Calculate Monthly Retention Performance

Hi

 

I am new to PowerBI and trying to create a POC for our business requirements.


Attached the dataset and information around the data. Could someone help me in find the monthly retention performance for the  product "flex".

 

customer_idproduct_nameinception_policy_ideffective_start_dateeffective_end_date
9515flex13155505-09-201705-09-2017
9515flex14284327-09-201727-09-2017
9515flex14579902-10-201702-10-2017
7863flex14624103-10-201703-10-2017
9515flex14749705-10-201705-10-2017
9515flex14836406-10-201706-10-2017
7863flex16999008-11-201708-11-2017
9515flex16985808-11-201708-11-2017
7863flex17524413-11-201713-11-2017
7863flex17790816-11-201716-11-2017
9515flex17950517-11-201717-11-2017
7863flex18628723-11-201723-11-2017
9515flex19908105-12-201705-12-2017
7863flex19955706-12-201706-12-2017
9515flex21016419-12-201719-12-2017
9515flex21280022-12-201722-12-2017
7863flex21662929-12-201729-12-2017
9515flex21870102-01-201802-01-2018
9515flex22038404-01-201804-01-2018
9515flex22610411-01-201811-01-2018
22597flex22603811-01-201811-01-2018
22597flex22606011-01-201811-01-2018
1991flex22687812-01-201812-01-2018
7863flex25375103-02-201803-02-2018
18820flex25433103-02-201803-02-2018
1991rsa22687810-01-201812-01-2018
7863rsa25375105-02-201809-02-2018
18820rsa25433108-02-201809-02-2018

 

Thanks very much. 

3 REPLIES 3
v-alq-msft
Community Support
Community Support

Hi, @karthikponnaih 

 

If you take the answer of someone, please mark it as the solution to help the other members who have same problems find it more quickly. If not, let me know and I'll try to help you further. Thanks.

 

Best Regards

Allan

v-alq-msft
Community Support
Community Support

Hi, @karthikponnaih 

 

I wonder the definition of monthly retention performance. If you want to count the number of records where the current month-year is between the start date and the end date and the product name is 'flex', you may try the following steps.

 

Table:

f1.png

 

Calendar:

 

Calendar = CALENDARAUTO()

 

 

You may create a calculated column and a measure as below.

 

Calculated column:
Month-Year = VALUE(FORMAT('Calendar'[Date],"yyyymm"))

Measure:
Result = 
var _monthyear = SELECTEDVALUE('Calendar'[Month-Year])
var tab = 
ADDCOLUMNS(
    ALLSELECTED('Table'),
    "startmonthyear",
    VALUE(FORMAT('Table'[effective_start_date],"yyyymm")),
    "endmonthyear",
    VALUE(FORMAT('Table'[effective_end_date],"yyyymm"))
)
var newtab = 
ADDCOLUMNS(
    tab,
    "flag",
    IF(
       _monthyear>=[startmonthyear]&&
       _monthyear<=[endmonthyear],
       1,0
    )
)

return
COUNTROWS(
    FILTER(
        newtab,
        [flag] = 1&&
        [product_name] = "flex"
    )
)

 

 

Result:

f2.png

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Greg_Deckler
Community Champion
Community Champion

Not sure what retentation performance means exactly. I can think of a number of definitions, what do you use?

 

Open Tickets might assist, it is designed to work with date intervals. https://community.powerbi.com/t5/Quick-Measures-Gallery/Open-Tickets/m-p/409364#M147



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors
Top Kudoed Authors