Subtable fetch error - Sub table loads data for the wrong row for "Today" stats:(


(Sony) #1

Hi Piwik team,

Very happy to see lot of features in every release. I have been using piwik for more than 1 year and we had our own set reports too. Let me explain my problem here.

This issue is related to subtable loading. All our custom reports are multilevel tables like reports under Actions tab. We are updating daily reports for every 20 mins.
Every now and then , click on main table row leads to wrong sub table or resulting ''no data available error. This seems to be very high priority bug in the reports.

I saw ticket #1024 on the same issue, but no progress until now.

can you please take this as high priority and help fixing this issue as this is very critical to websites which updates reports very frequently.

Please some one share some idea/approach to resolve this issue.

thanks in advance.


(Matthieu Aubry) #2

Did you set Time out in “General Settings” to 20 minutes (ie. 1200 s) ?


(Sony) #3

Hi Matt,
Thanks for the quick response.

I had set up cron job which runs for every 20 mins and 600sec (10mins) under general settings.

Any way I was running cron job so how the setting under general settings is going to effect, can you please explain a bit more here and how it is going to solve my problem.


(Sony) #4

Hi matt / Vipsoft,

I spent lot of time to figure out this issue, at least we decided to show some popup to users saying that the reports have been updated in the backend, please refresh the page to see latest data. But this seems to be also not easy.

  1. To figure out whether reports are old/new, we don’t know user last action time
  2. I have tried to compare the label of parent row with the one in the DB (As per Ticket #1024), this also does not work in one scenario. Lets take I have one report which shows total number of hits for each user in main table and list of hits in the subtable. After updating reports from backend, if we directly click on subtable (with out refreshing the actual page), it should get the new data and also parent row needs to be updated with the new number of hits, this is not possible right now as click to subtable is a AJAX request and it updates only part of the page.

Can some one please let me know if is there any way to tell the users about this backend archiving process and ask them to refresh the page.

This is the high priority right now from my client and am ready to implement the fix and share it to piwik team if some one gives some idea on the solution.


(Matthieu Aubry) #5

I don’t think it’s a trivial fix for this one. A solution could be to have a click pass the label of the row, and then use the label to search for the matching parent row, to fetch the subtable?


(Sony) #6

Hi Matt,

I already tried that solution by passing label from front end and comparing with the one from DB, but this solution not covering one scenario.
When we update the reports, sub table id’s may/may not change. If there is a change in subtable id , easily we can find out by comparing label. If there is no change in subtable id, in that case lable will be same but the summary numbers in the parent row will not match the numbers in the subtable (parent row is old data & sub table is new data). In this case we dont have any clue on whether reports are updated or not.

After clicking on subtable, if the numbers from parent row & subtable does not match, people may think as piwik reporting is not correct. Currently I am facing the same situation. As I mentioned in my previous mail, parent row contains total number of hits and subtable contains list of all hits.

Please give your inputs.