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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Pbiuserr
Post Prodigy
Post Prodigy

Measure takes long to execute

Hello,
I wonder why this measure is so slow. First I create INTERSECT from ID's from both dim and fact table 

Planned SKU = 
COUNTROWS(INTERSECT (
VALUES (DimTable[ID] ),
VALUES (FactTable[ID] )

and my final measure is 

Planned SKU by date =
CALCULATE (
[Planned SKU],
FILTER (
ALL ( 'date' ),
'date'[Date] <= MAX ( 'date'[Date] )
)
)

 

I have also one filter on that page which only let me take last 5 years into consideration

 

    'Date'[Date] <= EOMONTH ( TODAY (), 0 )
        && YEAR ( 'Date'[Date] )
            >= YEAR ( TODAY () ) - 5,
    1,
    0
)

 

 

 

I try to create area chart made of YearMonth as axis, this measure [Planned SKU by date] and cost center as the legend and it takes forever. Does anybody recognize at which part it can take so long?

 

1 REPLY 1
amitchandak
Super User
Super User

@Pbiuserr , Try like, I think simple countrow should also work

 

Planned SKU by date =
CALCULATE (
countrows(filter(Fact, not(isblank(related(DimItem[ID])) )),
FILTER (
ALL ( 'date' ),
'date'[Date] <= MAX ( 'date'[Date] )
)
)

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

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.