✆ UAE: +971 58 5616 616, ✆ USA:+14099168409,   ✉ info@insightcubes.com

Using the getDimensions() and getDimensionProperties() API’s with SAP Analytics Designer

How to use the getDimensions() and getDimensionProperties() API’s with SAP Analytics Designer.

getDimensionProperties() Returns all available dimension properties of the specified dimension of a data source. Only supported on data sources from table widgets. Mandatory parameter is dimension name.

In this blog we will be sharing an example use case for the getDimensions() and getDimensionProperties() API’s with SAP Analytics Designer.

We are sharing an example from our EPM Report Developer Analytics Application with SAP Analytics Designer. We used the API’s in two different ways, the first to get the dimensions and dimension properties form the table widget, the other use case comes very handy in our example, through a script object we apply the same code order to filter dimension properties of 8 dimensions to further expand the functionality needed for the EPM Report Developer Analytics Application.

Filtering reports using the getDimensionProperties() API

Using the getDimensions() and getDimensionProperties() API’s with SAP Analytics Designer on the table widget. This code will read all the dimensions added to the table on rows, columns and filters, and fetches the properties as well.

getDimensions() and getDimensionProperties() API’s on table widget

The second example makes life easy, we created Script Variables for all the dimensions we want to filter via property on. A dropdown for each, and a filter button that opens up a popup allowing the user to select any property from the selected dimension. Then used the getDimensionProperty() API in a Script Object that applies the request to the selected dimension depending on which dimension filter button was clicked.

Lets get started.

First we will create the popup, it will be one popup for all the dimensions filter button.

Dimensions Hierarchy, property and column/row selector

We have covered the hierarchy and add dimensions to columns/rows dropdowns in two other blogs.

In this blog we will cover the Filter criteria dropdown which will filter the dimensions according to property values.


Create a new popup, add the following code to its fx

Popup fx code

Place a dropdown widget into the popup, call it DD_DimensionProperties and add the below code to its onSelect fx.

DD_DimensionProperties onSelect fx code

We added a Checkbox Group in the popup pane add a title above it “Member selection Pane” as shown in the image titled “Dimensions Hierarchy, property and column/row selector”, this Checkbox will be populated with the selected dimension properties when the filter button of that dimension was clicked and a property was selected from the DD_DimensionProperties dropdown.


Create Script Variables for all the dimensions we need to filter properties on. In our case we created Script Variables for Entity, Account, Audit Trail, Currency, Flow, Interco, Scope and Version.

The measure Script Variable is used for another functionality that we will discuss in a separate blog.

Script Variables

Note: we will only be sharing the details of the Entity dimension in each step; users can apply the exact same steps for all the other dimensions.

In the below snippet, you can see the name of the entities Script Variable is “CurrentEntityFilterSelection”, with a type string, and a default value of the account we want to have populated before any filtering is applied. Flow’s default value is: [FLOW].[H1].&[F99]. Account’s default value is: [Account].[parentId].&[TBS]. Audit Trail’s default value is: [AUDIT_TRAIL].[H1].&[ALL_AUDITID], etc…

Entity’s Script Variable details

Creating the dimensions dropdowns and filter buttons that we will later link to the Script Objects so the order is passed to the table widget. We will show in details the steps for the Entity dropdown and filter button as we noted earlier, users can follow the same steps for all other dimensions.

Dimensions dropdowns and filter buttons

Entity dropdown onSelect fx code

Entity dropdown

Entity filter button onClick fx

Entity filter button fx

Create four more Script Variables:

SelectedDimensionInDropDown, Type: string.

SelectedDimensionInFilter, Type: string.

SelectedDimensionProperty, Type: string.

SelectedMembersInCBG, Type: string.

Create a Script Objects and call it utils_Context, and add three script functions:

setDetailedDimensionFilter:

Return Type: void.
Arguments: selectedDimensionPropertyValues, Type string, and set as an array.
And add the below code to its fx.

setSelectedMemberFromDropDown:

Return Type: void.
Arguments: SelectedMember, Type string.
And add the below code to its fx.

UpdatePropertyList: Return Type: void.
And add the below code to its fx.

Now you can filter your dimension per property.

Recent Posts

account configuration guide for the consolidation extension

Account Configuration Guide

Consolidation Extensions’ Account Configuration Guide The Account Configuration Guide serves as a preconfigured administrative tool designed to guide users with specific roles to effectively manage

Configuration Starter Kit

Consolidation Extensions’ Configuration Starter Kit The configuration of the Consolidation Extension for SAP Analytics Cloud can be conducted using a preconfigured toolkit. The purpose is

Audit Trail Configuration Toolkit for the consolidation extension

Audit Trail Configuration Toolkit

Audit Trail Configuration Toolkit Audit Trail Configuration Toolkit provides a comprehensive set of tools and resources to help developers easily configure the behavior of the

Scope configuration guide for the consolidation extension

Scope Configuration Toolkit

Scope Configuration Toolkit With our Scope Configuration Toolkit, you can take control of your consolidation scopes with confidence and precision. This interface makes it extremely

Get in Touch

Learn more and ask us About Our Cloud Consolidation Solution

Share This Post

Share this Page!

Share this with your network.

Want to Know More?

Get In Touch

Something isn’t Clear?


Feel free to contact us, and we will be more than happy to answer all of your questions.