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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Anonymous
Not applicable

Count of purchases within the chosen time filtered count of reviews (Double Filter??)

Hello PBI Masters 😃

Background: we have information like below:

Review NameReview DateProduct Purchase Date
Name A06/05/202004/30/2020
Name B06/25/202005/06/2020
Name C06/30/202006/21/2020
Name D07/05/202006/15/2020
Name E07/13/202004/30/2020
Name F07/15/202007/01/2020
Name G07/16/202004/30/2020
Name H07/25/202006/15/2020

 

Report filter pane has a time slicer for the users to choose a time period.

The whole report is filtered based on Review Date since that's the users interested in. 

 

The goal: (within the 8 reviews in the example in the table above)

When the user chose: Time Period: 06/01/2020 - 07/25/2020

The Review Count: 8 (because 8 reviews were posted during the chosen time)

The purchase count during chosen time period: 4 (because within those reviews, only 4 purchase were made)

 

When the user chose: Time Period: 06/01/2020 - 06/25/2020

The Review Count: 2 (because 2 reviews were posted during the chosen time)

The purchase count during chosen time period: 0 (because within those reviews, none purchase were made during the same period)

 

Please help 💛 lots thanks!

 

 

 

 

1 ACCEPTED SOLUTION
Icey
Community Support
Community Support

Hi @Anonymous ,

 

I modified @Ashish_Mathur 's measure like so:

 

Purchase count = 
CALCULATE (
    COUNTROWS ( Data ),
    Data[Product Purchase Date] IN VALUES ( 'Calendar'[Date] )
) + 0
Review count = COUNTROWS(Data)

 

 

And get this:

6.PNG67.PNG7.PNG

 

 

Best Regards,

Icey

 

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

 

View solution in original post

4 REPLIES 4
Icey
Community Support
Community Support

Hi @Anonymous ,

 

I modified @Ashish_Mathur 's measure like so:

 

Purchase count = 
CALCULATE (
    COUNTROWS ( Data ),
    Data[Product Purchase Date] IN VALUES ( 'Calendar'[Date] )
) + 0
Review count = COUNTROWS(Data)

 

 

And get this:

6.PNG67.PNG7.PNG

 

 

Best Regards,

Icey

 

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

 

Anonymous
Not applicable

Thank you @Icey  and thank you @Ashish_Mathur  for helping. 

Ashish's file plus Icey's modification on the measure made it perfect!

Have a great day ahead!

You are welcome.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Ashish_Mathur
Super User
Super User

Hi,

You may download my PBI file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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