Can we perform basic mathematical operations using two measures from two independent data sources?
For example, source A = SAP BW and we assign variable1 to measure X
source B = SAP HANA and we assign variable2 to measure Y
variable3 = variable 1 + variable 2 (measure X + measure Y)
Can we output variable3 back to a text component? I tried it and it doesn't seem to work
Any insight would be appreciated.
Hi Nishanth,
You should be able to achieve the desired result at run-time via scripting as follows:
1) Assign a specific Measure X value to Variable1 using script DataSource.getData().value against the BW data source
2) Assign a specific Measure Y value to Variable2 using script DataSource.getData().value against the HANA data source
3) Apply the mathematical operation with script var Variable3 = Variable1 + Variable2
4) Assign result to text component with script TEXT_1.setText(Variable3 + "")
Regards,
Mustafa.
Unfortunately that is not possible at design time; perhaps at run-time but not with a text box - see https://blogs.sap.com/2015/11/27/custom-measures-calculations-sap-design-studio-16/