Hi Team,
I am using tree structure in ignition vision.
Exporting the tree structure data in json format and importing that data to other server.
While importing json file, there is already some data present in treestructure and I want to merge json data with treestucture data.
I have converted json file to dataset and by using appenDataset() i am trying to append it.
It is appending the data but it is getting mismatched like below(Atest is existing and I importing BTest).
because of this treestructure not displaying data correctly
What am I doing wrong here?
Any idea?
Without seeing the two datasets, it's going to be hard to tell. 
I just created onedataset property on rootcontainer and assigned the imported treedata there.
it showing like this, here columns data getting mismatched.
I think column order is not same for these two database.
how can I do this with proper column order as per existing dataset?
Your headers are not in the same order as the default dataset. appendDataset() assumes the column order is the same.
In that instance, you need to specify the order. Something like this may help:
d1 = system.dataset.toPyDataSet(path.to.treeView.dataset)
d2 = system.dataset.toPyDataSet(path.to.imported.dataset)
headers = list(d1.getColumnNames)
data = [list(row) for row in d1]
for row in d2:
data.append([row[col] for col in headers])
dsOut = system.dataset.toDataSet(headers, data)
2 Likes