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

Shape the future of the Fabric Community! Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions. Take survey.

Reply
Leng28
Frequent Visitor

RT Measure very slow when selecting a recent date and super fast when selecting a date long time ago

Hello, 

 

i have a small problem. I have a table with sales over time (date time) each day is represented in a csv file. I visualise the sales over time in a line chart (time is rounded to the nearest half hour to reduce computing power). When i select a date long ago (01.12.2021) the visual will update almost immediately. When i select a date in the last days it takes 20-25 times longer. Each day has +-1000 the same row count. Any idea why that happens?

 

Thanks in advance 🙂

3 REPLIES 3
Leng28
Frequent Visitor

Hey @amitchandak,

 

this is the formula im using: 

 

Average Sales =
'Measure Table X'[RT Sales] / 'Measure Table X'[RT Rows]
 
RT Sales = CALCULATE(
Sum('X'[Sales]),
'X'[Time rounded] <= Max('X'[Time rounded]))
 
RT Rows = CALCULATE(
COUNTA('X'[Time rounded]),
'X'[Time rounded] <= Max('X'[Time rounded]))
 
I am not using a date table at the moment. 
amitchandak
Super User
Super User

@Leng28 , Share the formula.

 

Also, make sure you are using date table.

Change the join from date to int field 

 

Date key = year([Date])*10000 + month([Date]) *100 + day([date])

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

I think that the measure calculates the rt for the whole column and then the filter will apply. Thats why the calcualtion for specific dates (long ago) ist extreme fast and the other dates (recent days) is very slow. Any idea how i can apply a filter to the measure so only the selected date willm be calculated?

 

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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