Forum Discussion
Getting the next pages of a JSON API
Hi,
I'm trying to get data into PowerBI through an API. I chose "web" and connected the data like this:
= Web.Contents("myurl")
The data is loading to such format:
| next | (URL)?pageSize=5¤tPage=2 |
| self | (URL)?pageSize=5¤tPage=1 |
| events | [List] |
| statistics | [Record] |
I can only change the max page size to 2000, but I have way more records. Is there a way to load every page of the data?
I tried to find an answer, read many blog posts, for example from Chris Webb or this one https://medium.com/@marktiedemann/how-to-do-pagination-in-power-query-430460c17c78, but none of it seems to work (or I'm simply not able to apply it correctly)... any hints? 🙂
3 Replies
- Greg_DecklerCommunity Champion
- ImkeFCommunity Champion
Hi Anonymous ,
you can find a couple of approaches here: https://community.powerbi.com/t5/Desktop/how-to-create-a-query-that-paginates/td-p/20047
Please try some of them out. If they don't work, please post what you've tried so far with corresponding error messages to that we can narrow it down further.
- IceyCommunity Support
Hi Anonymous ,
Are the replies above helpful?
If they are, please always accept the replies making sense as solution to your question so that people who may have the same question can get the solution directly.
If not, please give us more details.
Best Regards,
Icey