Select cells contiguous to the pre-selected cell
I want to be able to select only the contiguous cells for my selected cell. Can someone please suggest me a way? I was looking for something like a relationship task to query the boundary sharing cells, however, I cannot find such tool in the workflow.
_img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=906f2000000XbqL&feoid=Body&refid=0EMf2000000YAPr" _/_img_
0
-
Here's a basic workflow that demos a way to do this:
https://drive.google.com/open?id=1ONl_sIxrJz9S-UOpOyEakwE-h-Fn2ZaA
What you need to provide in the Variables section:
1) your map service ID
2) your layer name
3) your geometry service
I designed the workflow to have the user click on the parcel they want to use, but you could also modify it to run as a workflow with arguments from a map tip (the first query task would just need to use a where clause instead of geometry to create the first feature set).0 -
Hi John,
Thank you so much for the reply. If I understood your correctly, it will still provide me with the corner cells (croosed off). As a requirement, our client does not want the users to be able to select those cells, only the cells sharing a boundary. Do you have any suggestion for this scenario? Your help is very much appreciated.
Thanks,
Amrit0 -
Ah, sorry, I missed that critical requirement.
Hmm, that's quite a tricky one. I played around a little bit with the sample workflow and tried replacing the Buffer Task with a copy of the Union Task further down, but that didn't matter.
It sounds like you're trying to replicate the "Share a line segment with" functionality of the select by location tool from ArcMap. I've got pretty much no experience with bringing geoprocessing services into a workflow, but maybe that's an option?0 -
Hi John,
Thank you for the suggestion. That is exactly what I wish to do: replicating the "Share a line segment with" scenario in Geocortex.0 -
It looks like the parcels to the East and South do not even share a boundary, so "Share line segment" wouldn't work there.
If all parcels are more or less equal in size, you could constuct a (multiline) geometry that goes through the center of a parcel, and slightly overshoots its boundary. The multiline would consist of two parts, one running E-W, and one N-S.
Another option would be to query by attribute. There seems to be some logic to the parcels numbering scheme (The"SE-19" part), so it should be possible to determine the bounding parcel's codes.0 -
Come to think of it, if the data doesn't change too often, it may be an idea to pre-calculate a table with neighbouring parcels, e.g. PARCEL NEIGHBOUR NW-19 NE-19 NW-19 SW-19 NE-19 NW-20 NE-19 SE-19 NE-19 NW-19 ... SE-19 NE-19 SE-19 SW-20 SE-19 NE-18 SE-19 SW-19 ...
Query this table first, and use the results to query the actual parcel table, e.g "PARCELCODE IN (...).0
Du måste logga in om du vill lämna en kommentar.
Kommentarer
6 kommentarer