Select to view content in your preferred language

How can I add customer data from my sql server database to a map layer?

2466
2
12-24-2016 06:52 PM
PaulPlayer
Deactivated User

1. How can I plot my sql database customer table on a map layer with a height bar representing total sales to that customer?

2. How can I represent the density of customers from my sql database customer table in a map layer?

0 Kudos
2 Replies
MoreHavoc
Occasional Contributor

Paul, 

That is a pretty wide open question, and there are several ways to approach and solve the problem, depending on exactly what your software or tool is supposed to do.  Here are a couple of ideas that might help:

  1. I know this isn't an "app" directly and this is a developer forum, but you could load the data into Excel, and if you have either lat/longs or addresses use the Esri Maps for Office tools to make some pretty cools maps.
  2. If this is just a regular SQL Server table, you need to first figure out how you are going to determine the location of each customer.  If you have an Address, you can use the Esri Geocoder to convert those into locations, I'm guessing the addresses don't change often so you may want to save those points in your database tables either as separate fields or using SQL Server Geometry to store it as a shape.  You could do this in the .Net API, or in Pro.
  3. Depending on how often this customer table changes, you could also load the data to ArcGIS Online and geocode it there into a hosted feature service, you will need to update it periodically though.  Once it is in a Hosted Feature Service you can add it to a web map and load up the map with different symbology in a .Net Runtime app pretty easy.
  4. If you want to access the data directly from the Runtime app, you could make the connection (If you are in .Net) to SQL server, and pull the data (you will need lat/longs, see item 2 above) and make a Graphics Overlay to show the points.

Once you can show the points you have lots of options for symbolizing it, you could use a 3D scene view and show sales dollars as a vertical cylinder, or you could use a 2D map view and change the size of a symbol or circle based on sales dollars.  You can use a Renderer to change the symbols based on data.

To represent the density you will need to create a hot-spot map, or do some clustering on the points.  If you load the data to ArcGIS Online you can use the analysis tools there to create these types of maps (I think you can do it in Maps for Office as well).  Once you have the results as a separate layer, you can pull that layer into a Map in .Net or, add it to an existing web map and load that in .Net.

If you have ArcGIS for Server (ArcGIS Enterprise) then you can do some different and additional stuff as well.

I hope this helps, not sure I'm going in the right direction!

Christopher

AnttiKajanus1
Deactivated User

Currently you can use GraphicsOverlays to show the features (or derivations of them) using Graphics. Basically the workflow is something like this 10.2.7 version but easy to adapt to the current release.

0 Kudos