cancel
Showing results for 
Search instead for 
Did you mean: 

SAC: setDimensionFilter exclude member performance impact

Hi,

I want to exclude a member from a table using the setDimensionFilter API. I'm passing the member id for filtering (member.id = "PM03"). This is working as expected (example 1), however, I've noticed in the script performance pop up that the member description is being fetched from the backend and impacting performance. sac-pop.png

When I apply a filter I use a MemberInfo array to alleviate the looping back to fetch the description (example 2).

When using exclude filters is there a way to use MemberInfo to avoid performance impacts/fetching description?

Thanks

Patrick

//Example 1: exclude member
DS_KPI4_Data_Table.setDimensionFilter("2CIPPOPCONTPROF",{value: "PM03",exclude: true});

//Example 2: using member info on standard filter
var memberInfos = ArrayUtils.create(Type.MemberInfo); 
memberInfos.push({id: "PM03",description: "PM03"});
DS_KPI4_Data_Table.setDimensionFilter("2CIPPOPCONTPROF",memberInfos);
JBARLOW
Contributor
0 Kudos

Hi there, patrick99 , bob.meincke

Out of interest - how do you access the performance metrics in app designer?

"I've noticed in the script performance pop up that the member description is being fetched from the backend and impacting performance. sac-pop.png"

Cheers

James

0 Kudos

Hi James,

?APP_PERFORMANCE_LOGGING=true

1. Add the above string to the URL after html

2. ctrl shift a to access widget

Cheers

Patrick

Accepted Solutions (1)

Accepted Solutions (1)

Bob0001
Advisor
Advisor

Hi patrick99 , good catch. There is currently no way to get around the additional request for loading the member description when using exclude (same for ranges). The only thing you can optimize for would be if you set the filter on multiple widgets. There you can use copyDimensionFilterFrom which would copy the filter without the need for fetching the member description again.

Would you always set the description to the ID in your case or would you have some more meaningful description at hand? Just asking to see in which direction this API method could evolve.

0 Kudos

Thanks bob.meincke

If we're applying filters by script the end user typically doesn't have visibility that it's been applied (we typically hide the header detail in the table) - hence passing the ID as the description. I do at times pass a meaningful description for my own sanity! I see the benefit of fetching the id & description via getResultSet or getMembers; especially when passing an array of values to setDimensionFilter.

Thanks again for the response. Appreciate it!

Patrick

Answers (4)

Answers (4)

0 Kudos

Thanks Surya,

We've already reviewed the best practice recommendations and have many in place.

As per example 1, I'm just trying to determine if we can pass MemberInfo via setDimensionFilter when using exclude.

Thanks

Patrick

surya_nallamolu
Explorer
0 Kudos

This note will provide you some information on optimizing the performance 2572550 in RSRT.

Also, on the model settings see if you can enable Enable “Optimize Story Building Performance“ and Enable “Optimize Performance for Two Structure Queries”

And you can try enabling query merge.

All these are SAP SAC best practice recommendations.

0 Kudos

Thanks Surya,

I'm using pause data refresh in this scenario. This is a live model. I'll have a look into RSRT re settings.

Thanks again

Patrick

surya_nallamolu
Explorer
0 Kudos

Did you try pause on refresh? Pause data refresh for the table and once you are done with your script and filtering enable the refresh this will reduce the number of times you are calling the query. Also, is this a live model? If yes, please use best practice at source side and also at sac side.

If BW there are some settings that you can enable in RSRT.

Thanks,

Surya Nallamolu