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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Improving performance of measure with multiple filter conditions

Hello everyone!

So, I have the following measure:

 

V.Received =
var same_day = FILTER(Table,YEAR(Table[LT_opened_at])&MONTH(Table[LT_opened_at])&DAY(Table[LT_opened_at])=YEAR(Table[qu_date])&MONTH(Table[qu_date])&DAY(Table[qu_date]))

return
CALCULATE(count(Table[hrc_number]),same_day)))

 

I also used the logic of "&&" logic to compare year, month and day but is slow as well.

My table has like 8M rows, it takes a long time to load when this measure is inside.
My table has date as rows, and this measure Bbasically its checking the number of rows where the lt_opened_at day matches the qu_date day that is being used in the table as row.

Any better idea on how to make such a measure?

Thank you!

4 REPLIES 4
Vvelarde
Community Champion
Community Champion

@Anonymous

 

 

Hi, Do you have a table like this?

 

Table.png

 

And you want to compare Row by Row If OpenedDate is equal to Qu_date?

 

Regards

Victor




Lima - Peru
Anonymous
Not applicable

Hello,

Yes, the qu_date will be used in the table row by row with the measure I mentioned.

Best Regards

@Anonymous

 

Hi, try with:

 

Measure =
CALCULATE (
    COUNT ( Table1[HRCNumber] );
    FILTER ( Table1; Table1[OpenedDate] = Table1[Qu_Date] )
)

Regards

 

Victor




Lima - Peru
Anonymous
Not applicable

I am trying to avoid that, cause I will need to change the data type on the database side and I need it for some calculations.. (knowing the time).  That is why I was doing this workout, but I think I do not have any other choice, maybe making two columns where one I just delete the extra details and make as you said

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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