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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Anonymous
Not applicable

Averge per header instead of line level

dear all,

 

I have the following table:

OrderOrderlineQ
A11000
A2500
A310000
B15000
B22500
C1400
C2200
C3600
C4600
 average =2311,1

 

The average of the lines is 2311, but i want an order average, which would look like this, with the following outcome:

 

OrderOrderlineQOrder Q
A1100016500
A2500 
A310000 
B150007500
B22500 
C14001800
C2200 
C3600 
C4600 
 average =2311,18600

 

So where all the Q's are summed together, and then taken the average, so you know the average Q per order.

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous ,

Try like

AverageX(Summarize(Table,Table[Order], "_1",sum(Table[Q])),[_1])

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@Anonymous ,

Try like

AverageX(Summarize(Table,Table[Order], "_1",sum(Table[Q])),[_1])

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

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

MayPowerBICarousel

Power BI Monthly Update - May 2024

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