cancel
Showing results for
Did you mean:

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Continued Contributor

## SUMIFs by subcategory

Here's a link to Excel data: https://www.dropbox.com/s/z9odcbbk1hnhd0i/Power%20BI%20Forum%20Sample.xlsx?dl=0

Here's a link to BI file: https://www.dropbox.com/s/rbjoqspdjdmtquq/Power%20BI%20Forum%20Sample.pbix?dl=0

In powerBI, I'm trying to create a measure to SUM the column [BASE] (BW in Excel) subject to the following filters:

GroupBY [Asset ID] (column B in Excel)

> [Count] (column BC in Excel)

< max[Count] for a given [Asset ID]   (e.g., some [Count]s associated with a given [Asset ID] are 60, some are 72, some are 120)

in Excel, the formula would look roughly like this:

=SUMIFS([Base],[Asset ID],[@[Asset ID]],[Count],">0",[Count],"<"&[@[Project Term (mos)]])

but I haven't figured out a simpler expression for the MAXIFS

1 ACCEPTED SOLUTION
Continued Contributor

This programming seemed to do the trick:

CALCULATE(
SUM('Table'[Base]),
ALLSELECTED('Table'[Asset ID]),
Filter('Table','Table'[Count]>0),
FIlter('Table','Table'[Count]<'Table'[Project Term (mos)]+1)
)
Continued Contributor

This programming seemed to do the trick:

CALCULATE(
SUM('Table'[Base]),
ALLSELECTED('Table'[Asset ID]),
Filter('Table','Table'[Count]>0),
FIlter('Table','Table'[Count]<'Table'[Project Term (mos)]+1)
)

Announcements

#### New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

#### Power BI Monthly Update - May 2024

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

#### Fabric certifications survey

Certification feedback opportunity for the community.

Top Solution Authors
Top Kudoed Authors