Last active
October 3, 2018 16:05
-
-
Save HanOostdijk/f2987aec8bd506f34535ee1b1d57162a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Remarks questions OData version 4 CBS beta. | |
- is there a place where I can post questions of this kind without troubling all followers of the LinkedIn group | |
`Centraal Bureau voor de Statistiek; Open Data` ? | |
- is there documentation about OData version 4 apart from the terrible https://lnkd.in/dkQMqWR and friends? | |
- Nesting of commands is not allowed? | |
The functions (?) `indexof` and `tolower` work standalone but using the filter | |
`$filter=indexof(tolower(Title),'gas') eq 9` returns an incomplete json statement: | |
{"@odata.context":"https://beta.opendata.cbs.nl/OData4/CBS-Maatwerk/900001NED/$metadata#MeasureCodes","value":[ | |
In browser (Firefox 62.0.3) | |
https://beta.opendata.cbs.nl/OData4/CBS-Maatwerk/900001NED/MeasureCodes?$filter=indexof(tolower(Title),%27gas%27)%20eq%209 | |
SyntaxError: JSON.parse: unexpected end of data at line 1 column 112 of the JSON data | |
- Is there a reason that the filter | |
$filter=(Id lt 6 and Id gt 3) or (Id eq 8) or (Id le 15 and Id ge 12) | |
on Observations returns the rows in the order 12,13,14,15,4,5,8 ? | |
It looks like they are sorted as characters. But I don't ask them to be sorted! | |
And if I ask them to be sorted | |
$filter=(Id lt 6 and Id gt 3) or (Id eq 8) or (Id le 15 and Id ge 12)&$orderby=Id asc | |
then they are sorted numerically 4,5,8,12,13,14,15 (as I would expect) | |
- implementation document https://beta.opendata.cbs.nl/OData4/implement.html | |
* under heading Metadata the old catalog (CBS) is used instead of CBS-Maatwerk | |
* the $filter(toupper) example has a copy-paste error | |
* $orderby seems to work (but is not mentioned) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment