Spatial Join to points "within selected features"

514
2
01-26-2021 09:01 AM
Labels (3)
JessicaJThompson
Occasional Contributor

Hello, 

I am relatively new to pro. I have been searching for the means to do a spatial join - one to many - only to the selected features within a layer. 

Specifics- I am working on a revitalization plan for 2 lower income neighborhoods. I have an national ACS layer with access to internet services data. I am looking to do a spatial join of the ACS data to only 2 of the neighborhoods in the municipal neighborhoods layer. 

I selected the 2 neighborhoods first, opened the spatial join tool by right clicking on the ACS layer in the TOC and proceeded from there. I ran the analysis and it was doing it for the entirety of the municipal neighborhood layer instead of just for the 2 that had been selected. 

I know I am missing something. Was also looking into Select By Attributes method similar and found this discussion Solved: Use selected polygon from layer to select points o... - GeoNet, The Esri Community

I can work my way around this for my current project, but I would love a solution for future analysis. Thanks in advance!

0 Kudos
2 Replies
DanPatterson
MVP Esteemed Contributor

depending on the selection type, sometimes reversing the order of the inputs works.  For example, instead of points in polygon, you do a polygon contains points


... sort of retired...
AngelaMarsh1
Esri Contributor

Hi Jessica!

Some GP tools automatically work on selected data only, and some do not (have a look in the esri help documentation per GP tool to see which ones work).

Alternatively, when your data is selected you can right click on the dataset in the Contents pane and from the dropdown menu select the option 'Selection'>'Make layer from selected features'. A new layer with only the selected features will appear in the Contents pane. You can then run the query/tool against this layer instead. When selecting this option, you arent creating a new dataset its just creating a new way to visualise/enquire/interact with that dataset based on the selection subset youve identified. 

Another option, is to set a definition query on your layer to only have the two neighbourhoods you want identified in the data 🙂

 

I hope this helps.

 

 

Happy Mapping