Welcome, Guest
Username: Password: Remember me

TOPIC: "display tokens" page empty when there are too many tokens(>15000)

"display tokens" page empty when there are too many tokens(>15000) 1 year 11 months ago #85373

  • siyang1982
  • siyang1982's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 5
  • Karma: 0
I import 16366 tokens from csv file.
Evenything works fine now, except when I click "display tokens" to see the list page, it is empty, the list is empty.
But I can export this list to csv file.

Why?

PS:
I find /index.php/admin/tokens/getTokens_json/surveyid/941689 returns 500 error.
But I can't find any error log about it.
In this function, it seems all data was loaded: $tokens = Tokens_dynamic::model($iSurveyId)->findAll(array("order"=>$sidx. " ". $sord));
Last Edit: 1 year 11 months ago by siyang1982.
The administrator has disabled public write access.

Re: "display tokens" page empty when there are too many tokens(>15000) 1 year 11 months ago #85374

  • siyang1982
  • siyang1982's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 5
  • Karma: 0
I fix this problem through update three lines:

......
/* $tokens = Tokens_dynamic::model($iSurveyId)->findAll(array("order"=>$sidx. " ". $sord)); */
$tokens = Tokens_dynamic::model($iSurveyId)->findAll(array("order"=>$sidx. " ". $sord, "offset"=>($page - 1) * $limit, "limit"=>$limit));
......
/* $aData->records = count($tokens); */
$aData->records = Tokens_dynamic::model($iSurveyId)->count();
......
/* for ($i = 0, $j = ($page - 1) * $limit; $i < $limit && $j < $aData->records; $i++, $j++) */
for ($i = 0, $j = 0; $i < $limit && $j < $limit; $i++, $j++)
......
The administrator has disabled public write access.

Re: "display tokens" page empty when there are too many tokens(>15000) 1 year 2 months ago #97387

  • dleger
  • dleger's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 18
  • Karma: 0
Fairly new on this... But I have the same issue... Only I tried to export about 12500 tokens...

Where are these lines that need to be updated? Which file?
The administrator has disabled public write access.

Re: "display tokens" page empty when there are too many tokens(>15000) 1 year 2 months ago #97390

  • siyang1982
  • siyang1982's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 5
  • Karma: 0
file: application/controllers/admin/tokens.php
function getTokens_json

I did this in previous version, I'm not sure whether it is working.
The administrator has disabled public write access.

Re: "display tokens" page empty when there are too many tokens(>15000) 1 year 2 months ago #97391

  • dleger
  • dleger's Avatar
  • OFFLINE
  • Fresh Lemon
  • Posts: 18
  • Karma: 0
Thanks. I'm a little frightful to change the code... But maybe someday I'll give it a try when I know usage will be down and I wont have to worry about the system being unavailable for a few hours in case I mess it up.

I did find an alternative this evening, in case anyone else runs into this isssue, which is to query the database directly. I logged into the mysql database and found the tables were actually quite easy to understand, and my web providers interface made it extremely easy to export the tokens file. It came out exactly as it would thru LS. Thanks again.

D.
The administrator has disabled public write access.

Re: "display tokens" page empty when there are too many tokens(>15000) 1 year 2 months ago #97399

  • DenisChenu
  • DenisChenu's Avatar
  • OFFLINE
  • Moderator Lime
  • Posts: 6276
  • Thank you received: 801
  • Karma: 241
Hello .

Maybe some Session issue: what happens if you deconnect/reconnect and look at token list ?

Can you report the bug : www.limesurvey.org/en/community-services/bug-tracker .

Remind : a bug not reported is a bug no corrected.
The administrator has disabled public write access.

Re: "display tokens" page empty when there are too many tokens(>15000) 1 year 2 months ago #97417

  • mdekker
  • mdekker's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 341
  • Thank you received: 68
  • Karma: 38
I reported and fixed the bug:

bugs.limesurvey.org/view.php?id=7954
---
Menno Dekker
The administrator has disabled public write access.
The following user(s) said Thank You: c_schmitz, DenisChenu
Moderators: ITEd
Time to create page: 0.126 seconds
Donation Image