on ‎2015 Aug 24 2:43 PM
Hi All,
I'm working on a near real time scenario where my data has to refresh on the Design studio application, without ending the session of the application, for every 30 minutes. I used the Realtime SDK -timer component and achieved a screen change. But the data refresh does not happen. I wrote DS_1.reloadData(); on the on timer script box for the timer component and restarted the timer. But this does not refresh my data.
I'm using DS1.5 as my client tool and BEx query as my backend. I checked a lot of discussions in SCN and the developer guide for DS1.5. Everywhere it says that reloadData() should refresh the data when there is no filter or variable change happening. But this is not happening in my case.
I tried setting a filter value and after a second changed the filter value as well and then did the reloadData() script again. But this does not work wither.
Is there any cache which I can reset or uncheck to refresh data? This is an important feature of the dashboard and is a major requirement. There will be no interaction in the dashboard and there are no variables for me to use. I can create variables but this will be as a last option.
Can someone please help me on this?
Regards,
Varshini.
Request clarification before answering.
Hi Tammy,
The Timer I'm using is the Real Time Package timer as mentioned in the discussion by Mustafa. I'll get you screenshots in a while.
Mustafa,
I'm using two timer components in my application. One is to change screens every 30 seconds, which works perfectly. The other is for the data refresh.I did try this out with an application.alert() on both timers and they worked fine.
I do not have issues with session expiration because the application keeps running without any timeout errors even after manual intervention after 4 hours. But the reload does not happen. The next thing I'm going to try is to have just one timer component and test the reloadData() script. If this works then Design Studio probably does not like having more than one timer in an application. But I'm not sure how it will help me.
Regards,
Varshini.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The AssignDatasource and LoadDatasource combination of scripts worked.Thanks Mustafa. The only drawback of this is that, I had done some changes on the edit Initial view of my data source. This seems to get reset. I'll have to reassign those changes.
Thanks. But does the reloadData() not work?
Thanks,
Varshini.
Hi Varshini,
The workaround using the AssignDataSource() and LoadDataSource() combination is intended for the case when the data source is a Universe because reloadData() is not supported for Universes up to DS 1.4, although from the DS 1.5 script content assist documentation it appears that this scenario is now supported.
However, in your case reloadData() should definitely work for a BEx data source. I was able to successfully verify this in my test system, with two timer components as shown below:
My scripts are as follows:
"On Startup" event of Application:
TIMER_1.start();
TIMER_2.start();
"On Timer" event of TIMER_1:
myTimer1 = myTimer1 + 1;
TEXT_1.setText(myTimer1 + "");
"On Timer" event of TIMER_2:
myTimer2 = myTimer2 + 1;
TEXT_2.setText(myTimer2 + "");
DS_1.reloadData();
"On Result Set Changed" event of data source DS_1:
dataChangeCount = dataChangeCount + 1;
TEXT_3.setText(dataChangeCount + "");
myTimer1, myTimer2 and dataChangeCount are defined as Global Script Variables of type Integer.
The last script is simply to verify that the data source is in fact being reloaded (because it is not visually obvious from the Crosstab update in my case since the backend data itself is static).
So, reloadData() should definitely work in your case. Perhaps you could reproduce the above test scenario to check the behaviour in your system?
Regards,
Mustafa.
| User | Count |
|---|---|
| 9 | |
| 4 | |
| 4 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.