Qlik Community

Qlik Sense Integration, Extensions, & APIs

Discussion board where members can learn more about Integration, Extensions and API’s for Qlik Sense.

Announcements
Customers, Partners & Luminaries only: You're invited to a Data Analytics Roadmap session. Read More
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Partner
Partner

Change master dimension or measure of visualization with Engine API

Hi All,

I'm using javascript to send commands to the Qlik Sense server engine, and using the ApplyPatches method on existing visualizations to change the master dimension or measure, to another master dimension or measure. The engine accepts the change, and a GetEffectiveProperties on the object shows the change to the dimension/measure has occurred in the qHyperCubeDef, but the change never gets persisted, even after a DoSave. Therefore, when I refresh  my mashup, the object reverts back to the original state. However, I've found that if I clear my cache and hard reload Chrome, I can successfully apply a single change to either the dimension and/or measure 100% of the time, but if I try to make a change again it DOES NOT work, unless I also change another property on the object (i.e. Change the dimension AND title), OR clear my cache and reload Chrome would work again as well. 

If I only change the title, using ApplyPatches, then DoSave, it works 100% of the time. I'm only having issues persisting the changes to the master dimensions/measures. 

Any assistance would be appreciated. I've also attached a video to be seen. 

 

Thank you,

Colin

2 Replies
Highlighted
Partner
Partner

What I have done as a workaround for the time being, is that with each property change, I am removing, then repopulating the value of a property that has no overall effect on the chart object. By toggling a non-master object property, then applying DoSave(), my mashup works as I would like for it to. Definitely not perfect or ideal, so some insight into the behavior would still be appreciated. Thanks!

Highlighted
MVP & Luminary
MVP & Luminary

Can you provide a sample mashup to rebuild the issue and test with latest version?

Vizlib Head of R&D