1. Spatial Data with SQL Server
Reporting Services
Using SQL Server Reporting Services you
can visualize spatial information in a report or
dashboard alongside other business data in
the form of tables, charts, or graphs that
present other facets of related information.
Mihail Mateev
Senior Technical Evangelist, TL @ Infragistics
2. About me
Mihail Mateev is a Senior Technical Evangelist,
Team Lead at Infragistics Inc.
Mihail worked in various areas related to
technology Microsoft: Silverlight, WPF,
Windows Phone 7, Visual Studio LightSwitch,
WCF RIA Services, ASP.Net MVC, Windows
Metro Applications, MS SQL Server and
Windows Azure
2 |
3. Agenda
Creating a Simple Report Map
SQL Server Spatial Data
SRSS Map Control Data Sources
Map Gallery (Installed Maps)
ESRI Shapefile
SQL Server Spatial Query
Customizing the Map Viewport
Adding an Analytic Dataset
Adding a Bing Maps Tile Layer
Windows Azure Reporting Services and Spatial Data
3 |
4. Spatial Data
Analyzing sales trends
Analyzing the best placement depending of
different criteria
Navigating to s destination using a GPS device.
4 |
5. Spatial Data
Allowing customers to track the deliveries
Finding the optimum route for transportation
tasks
Reporting geospatial information on the map
rather than in a tabular or chart format
5 |
7. Comparing Raster to Vector Data
Vector Data: Raster Data:
describes discrete represents spatial
spatial objects by information using a
defining the coordinates matrix of cells.
of geometries
Rows
X,Y X,Y X,Y
X,Y X,Y Columns
7 |
8. Geographic and Projected CS
Geographic Projected Coordinate
Coordinate System System
Y
Data
- X +X
+Y +Y
usually here
X
-X +X
-Y - Y
8 |
9. Spatial Data and SQL Server
Geospatial Data Types
SQL Server supports two different spatial data types:
GEOMETRY and GEOGRAPHY
9 |
10. Spatial Data and SQL Server
Using Spatial Objects
Create Spatial Objects
10 |
11. SQL Server Reporting Services
SQL Server Reporting Services (SSRS) is a server-based
report generation software system from Microsoft.
Administered via a web interface, it can be used to
prepare and deliver a variety of interactive and printed
reports.
11 |
12. SRSS and Spatial Data
Map Report Item and
Sources for Spatial
Data
Spatial data can be
provided to the Map
Report Item (Map Report 1. Map Gallery Reports
Control) in three ways:
2. ESRI Shapefiles
3. SQL Server spatial data
stored in a database
12 |
13. Map Layers
Multi layer support 1. Polygon – used to show
Each layer can contain geographic areas such
spatial data used to draw as countries or states.
the map, analytical data, 2. Line – used to show
and other properties such paths and routes.
as color and size. 3. Point – used to show
specific geographic
places.
4. Tile – used to display
Bing maps in reports.
13 |
14. Creating the Report Project
SQL Server Data
Tools
Report Server Project
Map Report Control
Spatial Data Source
14 |
15. Spatial Data Source
Tile Source
Shapefiles
SQL Server Spatial
Data
15 |
16. Customizing the Map Viewport
Map Projections
Center and Zoom
Fill, Border, and
Shadow
16 |
17. Analytical Data
Add an analityc
dataset
Match an analityc
dataset to a spatial
dataset
17 |
21. Assigning Actions to Map Elements
it is possible to add a Redirect to report with
degree of user interaction parameter:
to SSRS maps by
assigning actions to
elements on the map. SELECT CODE,
An action is triggered CNTRY_NAME,
when the user clicks on a POP_CNTRY, FIPS,
particular report element, geom.STArea() AS area
which can redirect them FROM world WHERE
to a new report or URL (CNTRY_NAME =
@country)
21 |
22. Assigning Actions to Map Elements
Select Polygon Properties
Select the Action tab
Select the Go to report
action and Specify other
report
Add a parameter
22 |
23. DEMO
Create a report with
spatial data from Bing
Maps, shapefiles and
SQL Server spatial
data
24. Windows Azure SQL Reporting
Windows Azure SQL 1. Preparing a database.
Reporting works the 2. Creating a New SQL
same as SQL Server Azure Reporting Server
Reporting Service – 3. Developing a Report in
but runs on cloud with BITS
some limitation such 4. Using Spatial Data with
Windows Azure SQL
as it connects only Reporting
with SQL Azure
5. Publishing Reports
database.
24 |
25. Preparing a Database
Windows Azure SQL 1. Create a new SQL
Database Windows Azure
Database server
2. Set Firewall Rules
3. Import Spatial Data
25 |
26. Creating a New Azure SQL Reporting Server
Windows Azure SQL 1. Create a new Azure SQL
Reporting Server Reporting Server.
2. Get the Web Service
URL
26 |
27. Developing a Report in BITS
Create a Report 1. Create a new Reporting
Server Project.
2. Add a Report
3. Add a new data source
4. Provide the query for
fetching the record from
database
27 |
28. Developing a Report in BITS
Create a Report 1. Add a Map control.
2. Choose a dataset with
SQL Server spatial data
3. Create a thematic map
28 |
29. Developing a Report in BITS
Create a Report 1. Select TargetServer URL
2. Publish the
Project/Report
3. Verify the Reports in
SQL Azure Reporting
Service
29 |
30. DEMO
Create a report with
spatial data from Bing
Maps, Windows
Azure SQL Database
spatial data using
Windows Azure SQL
Reporting