1

I have some datasets: Parks, Park facilities and ParkTrails. These have many-to-many relationship; i.e a park can have multiple facilities and there may be multiple park trails on a single park

I would like to publish this data to ArcGIS Server, and issue queries on it, so that I can get a single result for a single Park. Currently, when mapping say a pack I get all other parks and facilities as well as Park line and this is somehow confusing and a lot of information to digest at a time when the result is drawn by a text search.

Does anyone know how I can create a spatial view that will generate a unique Object ID field for repeated geometries to enable me publish a park layer with say uniquely identified facilities and park lines?

I am using MSSQL Database server 2012 and ArcGIS 10.4. I would also not want to tamper with my data storage type.

I have tried creating the view from my MSSQL interface but on bringing it across to ArcCatalog or ArcMap, I keep getting the OID error (ObjectID)and some other errors as shown in the screenshot attached here.

Also at some point, the feature displays on ArcMap to show just one feature either polygon data or the Line data but when I try to view the attribute table it gives me another error screenshot 2

enter image description here

enter image description here

  • 2
    You need to be extremely careful when modelling many-to-many with ArcGIS, since it has no tolerance for repeating rowid columns. I would recommend you denomalize your data by creating the Cartesian product in a table, then driving your queries through that. – Vince Aug 7 '17 at 22:14
  • @Vince I think you should make your comment into an answer – PolyGeo Sep 3 '17 at 2:08
1

As commented by @Vince:

You need to be extremely careful when modelling many-to-many with ArcGIS, since it has no tolerance for repeating rowid columns. I would recommend you denormalize your data by creating the Cartesian product in a table, then driving your queries through that.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.