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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Query - Filtering and Sum

Hi, I am new to Power Bi,

 

I am trying to work out my net adds for the month.

  • In excel I filter on the Start Date column i.e. October dates only.
  • I then need to sum the quantity column.
  • Leaving the filter on the Start Date column I then filter on the service End Date Column for October dates only. – I then sum the quantity column
  • I now have two sum figures
  • I take away the SumQuantity for Start Date & SumQuantity for Service End Date to work out my net adds

 

Can anyone advise which would be the best Dax formula for this or query?

 

I can post data if need be

1 ACCEPTED SOLUTION
v-frfei-msft
Community Support
Community Support

Hi @Anonymous ,

 

Setting the slicer to between as below should help you.

betwee.PNG

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

4 REPLIES 4
v-frfei-msft
Community Support
Community Support

Hi @Anonymous ,

 

Setting the slicer to between as below should help you.

betwee.PNG

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.
Anonymous
Not applicable

Hi   

That will work; however, I am producing my data in a matrix along with other measures. I am replicating a report in Power BI from Excel. See picture of data below. 

 

Capture.PNG

 

Hope this helps. 

 

@v-frfei-msft @Anonymous 

Anonymous
Not applicable

NetGroup2 = 
VAR StartDateNet = CALCULATE(SUM(Test[Quantity]),Test[Brand]="Group2",ALLSELECTED(Test[StartDate]))
VAR ServiceEndDateNet = CALCULATE(SUM(Test[Quantity]),Test[Brand]="Group2",ALLSELECTED(Test[StartDate],Test[ServiceEndDate]))
RETURN StartDateNet
Anonymous
Not applicable

Hi Vimal, 

 

Thank you for you're help so far. 

 

I have more than 1 brand in my data that I need to include. I can sort this by adding a filter on the visual.

 

My main concern is that is there no way to add a date field such as "DatesBetween" in the below dax expression? I want to Power BI to give me net adds for September only. @Anonymous 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors