Same blocks, two different length csv files, but one of them can't run correctly

66 views
Skip to first unread message

cc1608x

unread,
Jul 17, 2017, 1:01:39 AM7/17/17
to mitappinv...@googlegroups.com
I have a csv file that includes name, gender, class, account, password and course fields. First, read the csv file, then turn it to a list, and store data to TinyWebDB. If you click the button "Read WebDB and Display", it will read TinyWebDb and display the value. I use 2 csv files to test the app. The test_10.csv file has 10 items, and it runs totally correctly, the label3.text shows all items. The test_full.csv file has about 900 items, after clicking the button "Read WebDB and Display", the label3.txt shows nothing. What is the probable problem? video


Screen Initialize:

Turn csv file to list, delete the first and last brackets








Clicking  btnInitialize "Set Data Format":







Clicking "Read WebDB and Display"




But when I just change file test_10.csv to test_full, the last step cannot fulfill, the label3.txt shows nothing.



Here is a video: https://drive.google.com/open?id=0B8J1AltYGH0MdnlMQnc4dWdwOHc       to show the app running.


I have also upload the .aia file.














Enroll_Test.aia

Tim Carter

unread,
Jul 17, 2017, 3:19:56 AM7/17/17
to MIT App Inventor Forum
Why do you need to use the TinyWebDB? Looks like static data to me?

Abraham Getzler

unread,
Jul 17, 2017, 11:10:04 AM7/17/17
to MIT App Inventor Forum
This should be a Fusion Tables app.

See this sample for how to do multiple INSERTs from a csv table ...



Also, when you build your list of pairs from the split line,
you fail to guard against short (< 6 items) lines before
you go selecting items from the split result.

clean it up.
Watch for short line(s) at the end.

ABG


cc1608x

unread,
Jul 17, 2017, 11:48:31 AM7/17/17
to MIT App Inventor Forum
Thanks for your reply!

We can't use fusion table as well as MIT TinyWedDB in China. So we use our local TinyWebDB instead. In order to shorten the length of the list, I modify my progrem, don't use pair value at last. Finally I figure out what the problem is. I think it is because of the length limit of TineWebDB. When I seperate the total long list into 21 short lists, each list only include not more than 60 items, and then it can fetch value from TinyWebDB.
Message has been deleted
Message has been deleted

Abraham Getzler

unread,
Jul 17, 2017, 12:06:36 PM7/17/17
to MIT App Inventor Forum

Juliet

unread,
Jul 17, 2017, 12:55:58 PM7/17/17
to MIT App Inventor Forum
That's so appreicate of you! The power users FAQ is very helpful!
Reply all
Reply to author
Forward
0 new messages