Help me get this straight: arrays in database
I'm trying to understand how to store and retrieve arrays in/from the database. There's a lot of questions on this forum, and I read quite a lot, but I still don't really know how to do this. So I put up this test app.
First I made a testdatabase, containing a field with an array. I'm not quite sure how to store my data in the best possible format. I tried it like this, something lacking?
[
"{'key1': 'valuekey1rowA', 'key2': true}",
"{'key1': 'valuekey1rowB', 'key2': false}"
]
(key1 being a string, key2 a boolean)
So I build this testapp, you can see the front end at http://appery.io/app/view/56ec40aa-38....
First I tried to map this thing like this:
Looks nice and it does actually make two listitems. The sad thing is, it does not produce any text on the labels of those items. Am I making some kind of stupid mistake, or is the thing I'm trying to do here impossible?
I also read information making me try to first save the whole array as a local variable, and next converting it to a string, using JSON.stringify(). But I can't seem to map the whole array to a single local variable, or at least it doesn't show anything in my console. I don't know how to proceed using that method.
Thnx for helping me out.