Hello Walter,
Hello David,I want to use a filename.json as a kind of INI file, means I want to set certain default variabels out of the database. Now my questions are:
1.
If I set a query, how can I get the unique result of this query into a local variabel. I.e I want to set a new var with the single [Record.Name] I get out of my query? With Setvar "[NewVar]" "[Record.Name]" "String" I get an error ... undefined
This is an interesting question. Currently the only way to parse a JSON file is to use the Report control, which in fact do more because visualice the JSON data in an HTML table. However, currently is not possible to parse a JSON string and retrieve it using App Builder available actions.
Definetively I need to think on this because it's very interesting. Of course if you use pure Javascript (with the StartJS and EndJS actions) probably you can do it, but my intention is to made it easy by using some kind of App Builder action or actions. Currently we can get the content of a file using "SimpleGet" action or the HttpClient control, but these are not thinked specifically for JSON files.
Currently I am a little sick, Walter, but I promise you I take a look at this question asa quickly as possible.
2.
My database.json has the fields Name and Value. After a query with only 1 result/record I want to use the following Syntax:
Setvar "[[Record.Name]]" "[Record.Value]" "String" - possible or a similar solution?
Anidated variables is something not available and probably it's not a thing which we can implement more or less easily, to be honest. However, we have actions like "Loop" or "While" and with the help of these actions and other possible actions to deal with JSON of course we must access individual JSON fields or iterate over records. Not currently, but probably in a near App Builder release.
3.
Do you think abaout a RANDOM control/function ?
Do you refer to a Random action which provide us a random number? Yes; of course some random related actions can be useful and probably you can count with something like that in a near release of the program. If I am wrong and you refer to other thing, please, tell me.