A common question that I get when introducing the map feature in SQL Server 2008 R2 Reporting Services is why the map gallery is limited to maps of the United States and individual states in the US. The reason as I’ve heard it explained is that the political boundaries for other countries are sometimes in dispute and it was better to stay away from any legal issues that might arise from publishing a map as part of a software installation. Presumably that means that boundaries between states (and even towns) are not in dispute, but that’s not entirely true as a CBS New report highlights.
Border integrity notwithstanding, the good news is that even though Microsoft doesn’t give you international maps in the map gallery, you can do it yourself. The files that the Reporting Services installation provides are simply reports created using TIGER/Line Shapefiles available free from the United States Census Bureau and stored in the Program Files\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAssemblies\MapGallery folder. (Look in the Program Files (x36) folder if you’re developing on a 64-bit computer.) You can add your own reports to this same folder to update the map gallery.
You can’t add just any report to the Map Gallery for this technique to work. The report must contain a map with embedded spatial data. You can create such a report by creating a map using any of the three options for spatial data – map gallery, ESRI Shapefile, or a SQL Server spatial query. Then, on the “Choose spatial data and map view options” page of the Map Wizard, you must select the “Embed map data in the report” option as shown below.
Using the map that I created for my post earlier this year about the map control, I eliminated the point layer and then saved the RDL file to the map gallery folder. Then whenever I want to create a new map for France, I can select it in the Map Wizard as shown below.
If you plan to use this option for making additional maps available to report developers, be aware that you must do this on every computer using Business Intelligence Development Studio to create reports. If you have users creating reports with Report Builder 3.0, you also need to store the map RDL in the following location: C:\Program Files\Microsoft SQL Server\MSRS10_50.MSSQLSERVER\Reporting Services\ReportServer\ReportBuilder\RptBuilder_3\MapGallery where MSRS10_50.MSSQLSERVER is the name of the Reporting Services instance.