Forum Discussion
Power BI Azure Map
- 7 months ago
Just a follow up to close this forum. I change to ArcGis map and with the address all points went to the right location. So this was the solution in the end.
Hii Beto_Zambom
When using a single string like CompanyAddressLong, Power BI's geocoding engine searches globally. If a street name in Australia also exists in the US, the map may default to the US location if it has a higher "search relevance" in the Bing database
The Solution: 3 Steps to Lock Locations to Australia
Step 1: Set Data Categories
You must tell Power BI exactly what each column represents. This is the most common step users miss.
- In the Data pane, select your CompanyCountryCode column.
- Go to the Column tools tab in the top ribbon.
- Click the Data Category dropdown and select Country/Region.
- Repeat this for CompanyCity (set to City) and CompanyPostalCode (set to Postal Code).
Step 2: Create a Geographic Hierarchy
Creating a hierarchy forces Power BI to look at the address "inside" the city, and the city "inside" the country.
- In the Data pane, right-click CompanyCountryCode and select Create hierarchy.
- Right-click CompanyCity and select Add to hierarchy -> CompanyCountryCode Hierarchy.
- Add CompanyAddressLong as the final level of that hierarchy.
- Use this Hierarchy in the Location field of your Map visual instead of the single address column.
Step 3: Add "Australia" to the Address String (Optional but Highly Effective)
If you still see issues, create a calculated column that explicitly appends the country name to every address.
MapAddress = 'Table'[CompanyAddressLong] & ", Australia"
Set the Data Category for this new MapAddress column to Address.
Why this works:
- Contextual Geocoding: By categorizing the Country column as "Country/Region," you provide a global filter for the Bing Maps API.
- Hierarchy Priority: When you use a hierarchy, Power BI passes the country and city context along with the street address, eliminating ambiguity with US street names.
Summary for the Community
The map visual needs geographic context. Always categorize your columns under Column Tools and try to include a "Country" field in your visual's Location bucket to anchor the geocoding to a specific part of the world.
If this configuration fixes your map locations, please mark this as the "Accepted Solution" to help others with similar mapping issues!
- Beto_Zambom7 months agoFrequent Visitor
Hi AshokKunwar
I did all you asked for:
1. CompanyCountryCode -> Contry/Region
2. CompanyCity -> City
3. CompanyPostalCode -> Postal Code
Create also Geographic Hierarchy
Also the new column MapAddress
MapAddress = 'FactDataTotalSprayers'[CompanyAddressLong] & ", Australia"
The map a little bit better, but now 3 points still on US and 1 in Europe:
The interesting is this data set, with all other countries (I just have a part of the data only australia) do not have that error when they add the CompanyAddressLong.
- Beto_Zambom7 months agoFrequent Visitor
Just a follow up to close this forum. I change to ArcGis map and with the address all points went to the right location. So this was the solution in the end.