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

The FabCon + SQLCon recap series starts April 14th at 8am Pacific. If you’re tracking where AI is going inside Fabric, this first session is a can't miss. Register now

Reply
Bopps
Frequent Visitor

Average Days Traded for Regions

Hi there, 

 

Please help 🙂

 

I need to get the average days traded by region in my dashboard. 

 

Previously I used to distinct coiiunt the days that each terminal traded anfd then export to excel and average per region. This has become tedious as i now ahve multiple countries with multiple regions,

 

I am still a newbie to this asll so I attempted to right something to help, the below still returns the average days per terminal, which is great, but now I need this to return per region. 

 

Days Traded Dax =
SUMX (
SUMMARIZE (
'Sales by TPM',
'Sales by TPM'[TPMNUMBER],
"Days Traded", DISTINCTCOUNT ( 'Sales by TPM'[DATE] )
),
[Days Traded]
)
 
Bopps_0-1620631289102.png

 

 

Bopps_1-1620631303141.png

 

1 ACCEPTED SOLUTION

Perhaps this measure is what you want...

 

Average Days per Terminal =
VAR _UniqueTerminalDays =
SUMMARIZE('Sales by TPM',
'Sales by TPM'[TPMNUMBER],
'Sales by TPM'[DATE]
)
VAR _Numerator = COUNTROWS(_UniqueTerminalDays)
VAR _Denominator = COUNTROWS(VALUES('Sales by TPM'[TPMNUMBER]))
VAR _Result = DIVIDE(_Numerator, _Denominator)
RETURN
_Result

View solution in original post

4 REPLIES 4
amitchandak
Super User
Super User

@Bopps , You can try a measure like

 

AverageX (
SUMMARIZE (
'Sales by TPM',
'Sales by TPM'[region],
"Days Traded", DISTINCTCOUNT ( 'Sales by TPM'[DATE] )
),
[Days Traded]
)

 

 

correct the table name for region

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thanks, ive tried this. 

 

It seems to be returning the maximum though, the full number of days in the month. 

 

Bopps_0-1620634942288.png

 

I pulled the data into excel to see the true average, 

 

Bopps_1-1620634964647.png

 

 

Average for April 2021 should be 27,35

 

Not sure what isnt working? 

 

Could this be that the terminal is appearing for multiple products? 

This should matter becuase we are doing disticnt count for that terminal for the day? 

Perhaps this measure is what you want...

 

Average Days per Terminal =
VAR _UniqueTerminalDays =
SUMMARIZE('Sales by TPM',
'Sales by TPM'[TPMNUMBER],
'Sales by TPM'[DATE]
)
VAR _Numerator = COUNTROWS(_UniqueTerminalDays)
VAR _Denominator = COUNTROWS(VALUES('Sales by TPM'[TPMNUMBER]))
VAR _Result = DIVIDE(_Numerator, _Denominator)
RETURN
_Result

Thanks Paul, 

 

Ill give this a try too,

 

I had a work around that gave the aqverage dayts traded by subsituting the summarise from regions to by Termninal. 

 

A bit slower but is working 🙂 

 

You guys are amazing!! 

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.