How to create a layer that intersects two attributes

464
4
04-26-2021 03:46 PM
Labels (1)
cardiofaz
New Contributor II

Hi all,


I have one polygon feature class.

I am trying within this feature class to show clashes of polygons by specific dates. Does anyone know how the best method to do this within ArcGIS pro and then ensure it is picked up in real time?

I was thinking to do this with FME and it is straight forward with FME but wondering if Pro has another way of doing this?

0 Kudos
4 Replies
JonathanMcDougall
Occasional Contributor III

You have almost answered this yourself, I'd stick with FME to be honest as it would save having to write all the Python code. 

0 Kudos
jcarlson
MVP Notable Contributor

Do you mean you want to identify intersecting polygons, but only when they share the same date?

What's the source of the feature class? If it's in a database of some kind (Enterprise GDB, or something like SpatiaLite or GeoPackage), using a spatial SQL function could return these rows very simply. The functions and syntax may change, but it would look something like this:

SELECT
    a.objectid as first
    b.objectid as second
    st_union(a.shape, b.shape)
FROM db.sdo.table a
JOIN db.sdo.table b ON  st_intersects(a.shape, b.shape) and a.date_field = b.date_field

Even better, you can add this as a Query layer which will remain "live" as the underlying data is updated.

An alternative to this might be an Attribute Rule, though that will be Enterprise GDB only, and take a bit more to get established.

- Josh Carlson
Kendall County GIS
cardiofaz
New Contributor II

Thanks for the response -

I published it as a feature layer through the arcgis data store. It was simply using a geodatabase which we published and be great if we can do it in real time.

The query layer is a interesting concept. Is there anything that might work as a definition query which is published as a feature layer?

0 Kudos
jcarlson
MVP Notable Contributor

If the database is registered with the server, a query layer can be published as its own service! It won't be editable, but it works just like anything else. Even if it's pulling attributes from multiple tables, the end user won't see that, they'll just see the feature class.

- Josh Carlson
Kendall County GIS
0 Kudos