Closed paulian829 closed 1 year ago
Hi @paulian829, I have read the issue several time but still have a problem understand this.
You should have IMHO have everything you need in the "return data" part. Pyodata will for sure not write directly to file, but since you have either many dictionaries or even direct json response it should not be a problem. If you want to go through entity properties manually to somehow store json file as a just part of overall response, still does not need to be hardcoded - you should be able to go trough service.schema to place a loop on entity which is only important to you. Or grab the raw response and use a python library for json manipulation.
If this this is still not enough answer for you, please provide a failing test for a bug/feature request. I am sure you can find in existing test suite something as a good starting point. I am not actually able to see the real problem here just from the provided general description of the problem - so far seems more like a adapter code outside of pyodata library for your use case than something that should be part of this library.
Hi @paulian829 I see no response, so closing. If the problem still persist, please reopen with additional informations requested above.
Hi I had been struggling to convert the fetched data to a JSON format.
I need to convert the filtered Entity to a JSON file directly. This is possible if you know each property, the problem is we have over 300+ properties and it would be a problem if It will be hard coded.
idx['AccountCreatedByUser']
will also not work so make a list of the properties and then looping it to create a key object pair will not work.