cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
danzidpp Member
Member

Any help to make my tables load faster?

Hello,

 

I have product table by Store Level. When I add below three formulas, it will take really long time to load the table whenever I add some changes or whenever I refresh. Any idea how to make it faster? I did search online, and found some info, but not help me.  I am not sure how to use DAX studio and what I suppose to do with it.  If anybody know, please let me know.  (Enable load and include in report refresh already marked on tables)

 

WOH = IF(ISBLANK(CALCULATE([Total On Hand]/(([Qty. Sold Last 4 Weeks]/28)*7))),"NA",([Total On Hand]/(([Qty. Sold Last 4 Weeks]/28)*7)))

Location Stock Out = IF(ISBLANK(CALCULATE(DISTINCTCOUNT('Location Stock out'[Store Name]), FILTER('Location Stock out', 'Location Stock out'[Available] = "Yes"))),"-", CALCULATE(DISTINCTCOUNT('Location Stock out'[Store Name]), FILTER('Location Stock out', 'Location Stock out'[Available] = "Yes")))

True Stock Out = IF(ISBLANK(CALCULATE(DISTINCTCOUNT(Inventory_RQ[Store Name]), FILTER(Inventory_RQ, Inventory_RQ[Not in Stock] = "Yes"))), "-", CALCULATE(DISTINCTCOUNT(Inventory_RQ[Store Name]), FILTER(Inventory_RQ, Inventory_RQ[Not in Stock] = "Yes")))

 

Note- I am getting data from analysis service.

I already found this on community.

https://community.powerbi.com/t5/Desktop/Power-BI-Desktop-Visuals-slow-load/td-p/252881tempsnip.pngThank you so much

 

4 REPLIES 4
Community Support Team
Community Support Team

Re: Any help to make my tables load faster?

Hi @danzidpp,

 

Here I suggest to use SWITCH to work on it instead of IF function. Also kindly create measures separately.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
danzidpp Member
Member

Re: Any help to make my tables load faster?

Hey @v-frfei-msft

 

Thank you for the help.  I will try using SWITCH, but what do you mean by create measures seoerately. 

 

Thank you 

Danzidpp

Community Support Team
Community Support Team

Re: Any help to make my tables load faster?

Hi @danzidpp,

 

For example, for this measure. 

Location Stock Out = IF(ISBLANK(CALCULATE(DISTINCTCOUNT('Location Stock out'[Store Name]), FILTER('Location Stock out', 'Location Stock out'[Available] = "Yes"))),"-", CALCULATE(DISTINCTCOUNT('Location Stock out'[Store Name]), FILTER('Location Stock out', 'Location Stock out'[Available] = "Yes")))

 

We can create three measures separately to work on it.

 

Measure2=CALCULATE(DISTINCTCOUNT('Location Stock out'[Store Name]), FILTER('Location Stock out', 'Location Stock out'[Available] = "Yes"))
Measure = CALCULATE(DISTINCTCOUNT('Location Stock out'[Store Name]), FILTER('Location Stock out', 'Location Stock out'[Available] = "Yes"))
Location Stock Out = IF(ISBLANK([Measure]),"-", [Measure2])

 

Regards,

Frank

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Community Support Team
Community Support Team

Re: Any help to make my tables load faster?

Hi @danzidpp,


Does that make sense? If so, kindly mark my answer as the solution to close the case please. Thanks in advance.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.