Select to view content in your preferred language

Mapping Dynamic SQL Server XY Data

6952
3
01-13-2015 10:40 AM
AnthonyMuckle
Deactivated User

Hello,

quick question (while i search for the answer myself figured this might be quicker)

I'm pulling data from a sql server table which amongst other columns contains a couple for X/Y coordinates, the table will be updated from various sources at various times.

Completely new to gis/terminology and arcmap but a software dev by trade, so what i've currently done is.

  • Added the database connection, and a query to bring back the data I require.
  • Tried this as a query layer and created a feature class from xy data, assigning irish grid/assigned which columns to use for X/Y, published it
  • Referenced it in a viewer and the rest service

This gets the data brought back from the database fine, plots the points etc but...

But it's not dynamically calling the SQLServer each time so no changes are reflected unless i go in and republish/refresh the query. when

When i create my query layer etc from the database connection i'm assuming it's just creating a data-table and then this is getting published with the service to be used rather than it calling the sqlserver with the specified query for the current view of the data in the table each time.

Can anyone point me in the right direction for which type of layer/service/connection i need to use to dynamically get the results from sql so whenever the table is changed the viewer/layer reflects the changes without having to republish the service/have it use this static snapshot it seems to take on first run.

(same as this guy was trying to do pretty much)

Mapping Dynamic SQL Server XY Data in ArcGIS Online

cheers

Tags (2)
0 Kudos
3 Replies
AnthonyMuckle
Deactivated User

i've also registered the same sql server on the server i'm publishing on, But when i enable "feature access" when publishing the service it throws an error saying "the feature service requires a registered database"

so i pick my sql connection from the list available validate it and hit ok, but it continues to throw the same error when i analyse/publish

0 Kudos
FrancesCurtis
New Contributor

you need to enable GEOMM in your SQL Server database, and don't convert your Query layer in ArcGIS to a feature class, leave it as a query layer... that should do the trick

0 Kudos
NSum
by
New Contributor

If you leave it as a query layer will it display geospatially in ArcMap?

0 Kudos