Open amitnagraj opened 1 year ago
I would suggest to parse the data into a local variable and then append that to the final tree, lyd_parse_data_mem()
is not able to append data to an existing tree.
Thanks for the quick response.
Parsing the data locally will be costly when dealing with the large scale datasets, Is there any other way like lyd_new_path()
which is able to append the data everytime.
Parsing the data locally will be costly when dealing with the large scale datasets
I do not understand why it should, you said you had already been parsing it one-by-one. Just store the result in a local variable and append it. It depend on the exact data you are parsing and the tree you are constructing but I guarantee that there is a (simple) way of not affecting the performance in any way.
Hi,
I m trying to fetch the data using
lyd_parse_data_mem()
subscribing at the parent level(which also includes list inside it). I m filling the values by forming string of json format and passing it thelyd_parse_data_mem()
API. I'm using the API multiple times to fill multiple list levels. But only the data which is filled last is visible by this method.Is there any way so that the data will amend every time when i use this API?
Sysrepo version used: 2.2.12 Libyang Version used: 2.1.4