PDA

View Full Version : Loading JSON without field names into store



thomyorke
10 Mar 2011, 8:58 PM
I can load stores fine w/ JSON that has field names that match the field names in models as such:


{
"data": [
{
"value1": "1",
"value2": "2",
"value3": "3",
"value4": "4"
},
{
"value5": "5",
"value6": "6",
"value7": "7",
"value8": "8"
}
]
}


However, is it possible to load JSON without field names? The following JSON is valid, according to jsonlint:



[
[
"1",
"2",
"3",
"4"
],
[
"5",
"6",
"7",
"8"
]
]



I'm asking because my existing desktop application has the latter JSON layout, and would like to reuse these database calls.

Any help would be appreciated, thanks!

vishalnnsingh
10 Mar 2011, 11:16 PM
Have a look, this may help
http://www.sencha.com/forum/showthread.php?104389-Loading-a-JSON-without-field-name-assigned-to-it