question

kanupriyaGoel-0355 avatar image
0 Votes"
kanupriyaGoel-0355 asked rbrundritt commented

Get totalResults from GetSearchPOI

I am running a query

Query = "Petrol STations"
CountrySet ="GB"

Totalresults returned are 9600, as per documentation I cannot get more than first 2K records. Is there a way this can be done, any workaround?

I am not able to find a way to put in any request for this and this is very important for my business use case.

Any help is appreciated.

Thanks,
Kanupriya

azure-maps
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

rbrundritt avatar image
0 Votes"
rbrundritt answered rbrundritt commented

As per the documentation, this service only allows you to retrieve the first 2,000 results. You can however look at breaking and filter based on category set. In most cases you would end up being able to retrieve all the POI's, with the odd case where there is more than 2,000 of the same POI type in the same area.

What is your business case that requires retrieving all these POI's? There are some other services we are investigating which might better suit your needs in the future.

· 4
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

The category set for gas stations is 7311 which is same for all POIs and my use case is to fetch all gas station addresses in UK. This is required for a project I am working on for my organization.

In past I had been able to split based on country and category to get data but this time

I get approx 9632 records for 1 country and 1 category that need to be returned.

I also tried using async calls and search fuzzy api, but there as well same offset rules apply for a single query in query batch set

0 Votes 0 ·

In that case, make use of the btmRight and topLeft parameters and break the search area up into a grid.

Since I don't know the exact details of your scenario, be sure that they align with the terms of use for Azure Maps: https://www.microsoft.com/licensing/terms/productoffering/MicrosoftAzureServices/MOSA#ServiceSpecificTerms Primarily the database creation and caching restrictions.

0 Votes 0 ·

Thanku, I will try this.

Is there any plan in future to support such scenarios where offsetting won't be limited or bulk download option for the results.

We are not creating a database or caching the results.

0 Votes 0 ·

No. Bulk downloading is typically done by people who want to create databases or resell the data which is against the terms of use.

0 Votes 0 ·