JSON Remote DataSets

Hi Everyone,

I’m having some issues with my remote DataSets that I hope someone might be able to help me with. For context, the dataset JSON contains the now playing information for a radio station.

I’m having two issues with this.

  1. The remote JSON contains the information for 5 songs. I would like the DataSet truncated so that it only ever contains the contents of the JSON file (i.e. When a new JSON file is loaded, the data in the table is overwritten). However, if I set truncation to ‘Always’ under the advanced settings, the data table is always added to rather than overwritten. Is there a way to achieve the desired result here? Am I using truncation wrong?

  2. In my JSON file (the format of which I do not control), the artists are included as an array (this always contains one string). I have tried setting the column Remote Data Path to both artists (the name of the array object) and artists[0] (the string I am interested in). But neither seems to parse the JSON correctly. The documentation refers to ‘JSON Syntax string’ but doesn’t clarify what these are.

Any help anyone can provide would be much appreciated.

It seems that there is an issue with truncating the dataSet data in the task that does fetch the data from remote source - I’ve created the github issue for it with the fix as well.

As for 2., can we see remote dataSet url that you’re using, assuming it is available over the internet, if not, the .json data returned when you test the url in Xibo?

Hello!

I don’t speak very well english, so I’m not sure that is the same problem as me.

But I can’t to recover the JSON data when there is more than one level nested.

My JSON :

{“Statut”:“OK”,“Donnees”:{“0”:{“idUser”:“1”,“idClasse”:“1”,“prenom”:“Caroline”,“nom”:“Desgalier”},“1”:{“idUser”:“2”,“idClasse”:“1”,“prenom”:“Mickaël”,“nom”:“Leuba”},“2”:{“idUser”:“3”,“idClasse”:“1”,“prenom”:“Damien”,“nom”:“Boillat”},“3”:{“idUser”:“4”,“idClasse”:“1”,“prenom”:“Gwenaëlle”,“nom”:“Petermann”}}}

In this case, Xibo return : []

But if I give this JSON :

{
“Statut”:“OK”,

  "0":{  
     "idUser":"1",
     "idClasse":"1",
     "prenom":"Caroline",
     "nom":"Desgalier"
  },
  "1":{  
     "idUser":"2",
     "idClasse":"1",
     "prenom":"Mickaël",
     "nom":"Leuba"
  },
  "2":{  
     "idUser":"3",
     "idClasse":"1",
     "prenom":"Damien",
     "nom":"Boillat"
  },
  "3":{  
     "idUser":"4",
     "idClasse":"1",
     "prenom":"Gwenaëlle",
     "nom":"Petermann"
  }

}

Xibo return :

{
“entries”: [
{
“0”: {
“idUser”: “1”,
“idClasse”: “1”,
“prenom”: “Caroline”,
“nom”: “Desgalier”
},
“1”: {
“idUser”: “2”,
“idClasse”: “1”,
“prenom”: “Mickaël”,
“nom”: “Leuba”
},
“2”: {
“idUser”: “3”,
“idClasse”: “1”,
“prenom”: “Damien”,
“nom”: “Boillat”
},
“3”: {
“idUser”: “4”,
“idClasse”: “1”,
“prenom”: “Gwenaëlle”,
“nom”: “Petermann”
},
“Statut”: “OK”
}
],
“number”: 1,
“processed”: [
[
{
“Valeur”: “Statut”,
“User”: 0
},
{
“User”: 0
},
{
“Valeur”: “1”,
“User”: 0
},
{
“Valeur”: “2”,
“User”: 0
},
{
“Valeur”: “3”,
“User”: 0
}
]
],
“messages”: [
“Processing 1 results into 2 potential columns”,
"Processing Result with Data Root ",
“DataRoot is an object”,
“Processing as Multiple Rows”,
“Processing Statut”,
“Processing 0”,
“Processing 1”,
“Processing 2”,
“Processing 3”,
“Consolidating entries”,
“There are 5 entries in total”
]
}

How can I make the JSON to have severals colomns (idUser, idClasse, firstname, lastname) and severals rows?

Thank you to help me.