Forum Discussion
Get data using REST API Ringover - POST method
- 5 years ago
Hello PhilipTreacy
Finaly my colleague Data Architect found the solution.
The LasIdReturned in GetPage row 24 "LastIdReturned = try List.Last(Json[#"call_list"])[cdr_id] otherwise 0," was in conflict with all the "LastIdReturned" before.
So he have rename all the "LastIdReturned before" by "LastId" and now it's works very well.
Thank to yo again for youur time.
BR
Julien
Hi PhilipTreacy ,
Thanks for your answer, the code don't work and do exactly what you say.
I tried different way using this topic but i can't figure that.
Your right the iteration part have an issue.
Thanks a lot, i will investigate in this way, if you have any suggestion, let me know.
BR,
Julien
Hi Julien7438
Can you be specific about how it's not working. Is it generating an error? Is it giving you unexpected results? Can you share what output the query does generate?
regards
Phil
If I answered your question please mark my post as the solution.
If my answer helped solve your problem, give it a kudos by clicking on the Thumbs Up.
- Julien74385 years agoNew Member
Hi PhilipTreacy
For example if I set the StartDate parameter to "2020-10-27", the query will generate a number of lists, precisely 42 which is normal because each list contains 100 records (rows) and I know the database has generated 4200 rows since that date (42 * 100).
But in reality I have the same unique list 42 times, so when I remove the duplicate I only have 100 rows (my first list).
I didn't find how to share a photo or screenshot, so, I hope I was clear.
Thanks again for your time.BRJulien- Julien74385 years agoNew Member
Hello PhilipTreacy
Finaly my colleague Data Architect found the solution.
The LasIdReturned in GetPage row 24 "LastIdReturned = try List.Last(Json[#"call_list"])[cdr_id] otherwise 0," was in conflict with all the "LastIdReturned" before.
So he have rename all the "LastIdReturned before" by "LastId" and now it's works very well.
Thank to yo again for youur time.
BR
Julien
- ArturoMP4 years agoNew Member
Hi Julien,
I've been trying to do the same thing as you. Not really a pro with PowerQuery.
Tried your solution but all I receive is duplicated entities. If I choose 100 entities per page, it fetch 100 entities and then duplicates them.
I tried the solution you published afterward but it changes nothing, maybe I didn't understand you. Can you copy&paste the new code or something?
My aim is to gather all the calls from Ringover from a selected startdate and then update new data everyday acumulatively.
I hope I can still reach you!
best regards!
Arturo