How to import shapefile polygon into Power BI and display on map in BI

2092
4
02-02-2021 01:24 AM
Yshg1990
New Contributor

Hello,

I'm just trying to import shapefile polygon into BI, and display it,
but could not find the way so far.

What I have tried was
1) converted shapefile polygon into TopoJSON
2) Used "Shape Map" in Power BI
   - select random file for "Location" input in Field tab (just I used lat-long table),
   - select TopoJSON file for "Shape" input in Format tab
...but failed...

What I have expected was to display polygons on bubble map in BI.

It would be thankful to provide me how to realize it. 

Thank you,
Yshg

4 Replies
JonEmch
Esri Contributor

Hello there,

    So In ArcGIS for PowerBI, there isn't a direct way to input a shapefile, unless it is published to ArcGIS Enterprise or ArcGIS Online. If the shapefile is, lets say, a zip code or another polygon location type (state, county etc) then this would import as a polygon.

ArcGIS Enterprise Product Advocacy Lead
Keep on keeping on!
BenCoubrough
Esri Contributor

Hi @Yshg1990 ,

As mentioned by Jon, you cannot input a Shapefile into ArcGIS Maps for PowerBI.

If your Shapefile has a Location attribute however, you could convert the .dbf component of the Shapefile into a .csv file which can be imported into ArcGIS Maps for PowerBI and display it using that Location attribute.

You can view the documentation here:

I have done an example below, where my Shapefile had the address of the points split into a few different fields. I needed to create a new column with these attributes combined in order to display the location.

You can do that too by following this article - Create a separate Location column in your data

  1. Open MS Excel
  2. Open the .dbf file of your Shapefile. You might need to select "All Files" from the file explorer. You can then save the file as a .csvImportDBFtoExcel.pngConvertDBFtoCSV.png 
  3. Open PowerBI Desktop, then add the ArcGIS Maps for PowerBI Visualization and sign in with your account.
  4. From the Get data tool, connect to Text/CSV then navigate to your new .csv file and load the data.
  5. Drag your location column (or create your own) into the Location field

     

    customcolumn.pngAddressLocation.png

 

Voilà!

Your Shapefile data is now displayed in ArcGIS Maps for PowerBI. This method works well with point address data, or polygon data that is using locations such as zip codes, postcodes or administrative boundaries.

Yshg1990
New Contributor

JonEmch-san, BenCoubrough-san,

Thank you so much. I much appreciate your kind instruction.

As your instruction, I tried to look into .dbf file, but found that the format is just the series of 0...
The map I'm working on is about 1km×1km with no buildings.
Bubbles are corresponding to the amount of water production...hot spring field. 
(It seems too small to define physical addresses of my polygon)

Then, I am wondering how to extract table that suits BI format in ArcMap.

Thanks again,
Yshg1990

0 Kudos
AndrewStauffer
Esri Regular Contributor

From your Desktop GIS of choice, you should be able to export the data as a CSV, which can be used in Power BI if you have POINT data. Power BI does not support other geometries at this time. If you wanted to use polygons, you can separate the business data from the shape data, publish the shape data to ArcGIS Online and add that feature layer to Power BI. Then based on a common attribute/field value you can join the business data to you geometry. 

You cannot style the data based on the joined data, so you will want to style the geometry layer before you add it to Power BI.

 

Hope that helps,

Andrew

0 Kudos