Just as an aside, if you take a look at the requests in the network inspector, you will find that the associated data is returned to a grid within a single request, à la mode de vue de la base de données. Try find a grid with an associative column and check out the request body, you can test with curl
#!/usr/bin/bash
curl\
"https://foo.bar.co.za/xas/"\
-H "Accept: application/json"\
-H "Accept-Language: en-US,en;q=0.5"\
--compressed\
-H "Content-Type: application/json"\
-H "X-Csrf-Token: cff2bb51-6beb-4b41-b522-1b25371c73b3"\
-H "Connection: keep-alive"\
-H "Cookie: originURI=/login.html; XASSESSIONID=12345678-1234-1234-1234-123456789abc; xasid=0.12345678-1234-1234-1234-123456789abc; DeviceType=Desktop; Profile=Responsive" -H "TE: Trailers"\
--data @exX.json|\
jq \
'.mxobjects'
With exX.json with Schema as follows
{
"action": "retrieve_by_xpath",
"params": {
"xpath": "//Foo.Bar",
"schema": {
"id": "12345678-1234-1234-1234-123456789abc",
"offset": 0,
"sort": [
[
"ApplLogDate",
"desc"
]
],
"amount": 20
},
"count": true
},
"profiledata": {
"1567079664351-131": 331,
"1567079701730-132": 21,
"1567079704390-133": 27
}
}
...or without, as follows
Note that without the id field specified in the schema, no associated data is returned. How does one get/generate the schema guid?
Hi Dragos,
Did you solved your problem eventually? I am having the same struggle, so maybe you can help me out by providing an example as Mendix does give us only the most easy ones...
Kind Regards,
Beyza