J535D165 / cbsodata

Unofficial Statistics Netherlands (CBS) open data API client for Python
http://cbsodata.readthedocs.io/
MIT License
42 stars 17 forks source link

Fix URL parameters for nextlink #15

Closed J535D165 closed 4 years ago

J535D165 commented 4 years ago

Large datasets might raise an error after fetching a large number of subsets (of 10k). The issue is in duplicating the format=json parameter.

https://opendata.cbs.nl/ODataFeed/odata/83251NED/TypedDataSet?$format=json&$filter=startswith%28RegioS%2C%20%27GM%27%29%20and%20Geslacht%20ne%20%27T001038%27%20and%20Leeftijd%20ne%20%2710000%20%20%27%20and%20Leeftijd%20ne%20%27T001249%27&$format=json&$filter=startswith%28RegioS%2C%20%27GM%27%29%20and%20Geslacht%20ne%20%27T001038%27%20and%20Leeftijd%20ne%20%2710000%20%20%27%20and%20Leeftijd%20ne%20%27T001249%27&$skip=20000&%24format=json&%24filter=startswith%28RegioS%2C+%27GM%27%29+and+Geslacht+ne+%27T001038%27+and+Leeftijd+ne+%2710000++%27+and+Leeftijd+ne+%27T001249%27;5-8-2020 17:19

Resolves #5 (although this was considered a problem on the API server side, this might resolve the issue).