Hello I have been experimenting on charting some data from a database to a web form but have run into issues.
First, reading the documentation the 'Addressing Single Entity' does not seem to work. Accordingly the URL should work: https://app.devgems.com/music/Artist(3). Also the online TMS demo single entity returns null as well.
Using the XData guides I've managed to get data in the form of:
Which is the first element of a TJSArray. Is there a way I can easily extract all the "SeriesDate" and "SeriesValue" of this TJSArray and plot it in FNCChart/Any other charting packages?
Addressing Single Entity works as expected. If there is not artist with the specific id ("3" in this case), it will return null. If you change "3" by "50" for example, it returns a value (at the time I'm writing this answer - it might change if someone deletes it).
Regarding series, you just need to return a json array and set it to the chart or any other control. How you have managed to return the SeriesData? If you are using entity publishing, just use the endpoint that returns array of SeriesData. If you are using service operations, return a List<TSeriesData>.
I'm now looking through the XDataWebClientDemo source code and documentation and it seems entity publishing seems the easiest method for my uses. However I'm not quite sure how to get the endpoint from for example (https://app.devgems.com/music/Artist(6)/Name/$value) into Delphi using XDataWebClient or must I go through Response.Result.
As you can see above I have hard coded a date to get a single SeriesValue for now, could you point me towards some solutions to get a full plot going. I am thinking obtaining arrays of SeriesDate and SeriesValue only but unsure of how to implement that. Furthermore is it possible to index through rather than specify the key?