INTRODUCTION
An analytical application in SAP Analytics Cloud (SAC) is a dynamic and interactive digital interface that combines various visualizations, charts, and data-driven elements. The dynamic interactivity and customizability of analytical applications in SAP Analytics Cloud enables users to explore real-time data, carry out challenging computations, and concentrate on certain activities.
CONTENT
The case here is we need to apply filter to a chart that is placed inside the popup window, Whenever the specific dimension in the chart is clicked, the popup should be opened along with the selected dimension applied as filter in the popup chart and after clicking close, the selected filter should be removed, and chart should be refreshed back to normal without any selection.
Initially I have created an Analytical Application and used created a model using sample excel data.
Supermarket_sales is the model that I have created
The layout of my analytical application is shown in the image above. I have made one chart in the canvas and one chart with a popup window inside of it in the popups.
Chart_1
Therefore, I have used sales as the measure and City as the dimension in this chart_1. City is the filter I used, and it must be applied inside the pop-up window's chart.
Popup window
The popup window contains a chart and two button named ok and cancel.
Chart_2 (Chart inside the popup window)
In this chart, I have chosen unit price as measure and gender as dimension.
SCRIPT TO APPLY FILTER
The script was written inside the onselect function of Chart_1.
The script and the description is explained below.
We can also do more selection so that it gets stored in the respective index and the current last index will apply as a filter using a
for loop.
POPUP_1 ONSELECT SCRIPT
The above is the script that I have used in the onselect function of popup_1.
Using this script, by clicking the cancel button, the popup should be closed, that is written using if condition.
CONCLUSION
So, this blog explains how to apply a filter taken from one chart to another chart in an Analytical Application. If you have any queries related to this post, kindly leave the comment. Thank you.