<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic SQL Select Attributes from a Table &amp;gt; Intersect with feature &amp;gt; remove intersecting features with Modelbuilder in Geoprocessing Questions</title>
    <link>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099017#M25841</link>
    <description>&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;The goal with my model is to locate features that intersect a feature class of sewer mains. After a sewer main is determined to intersect with a feature I need to remove the ability to select that feature from the list then continue. Right now I'm using a Switch Selection to select all the features that are left minus the previously selected mains, but unfortunately this idea doesn't work because if there were zero features selected during the intersect process the switch selection will result in returning the entire original table which would ruin the process of eliminating mains as I proceed down the list of features I need to intersect with.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;I'm going to try to break this down in a linear format to make it easier to understand.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" size="3"&gt;Select sewer mains that Intersect with a Buildings feature class &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Assuming there are results create a feature layer from the selection &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Perform a Switch Selection on the sewer mains table to find the remaining sewer mains &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Use the Select by location to find the intersection of the remaining sewer mains against railroad tracks &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Create a feature layer for those &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Repeat until through the list.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;I'm certain there are better ways to do this using Modelbuilder, but I'm mentally blocked from seeing them right now. I need some help please.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;Also, I'd like to use Modelbuilder for this and not Python right now.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;I'm pretty sure I'm making this more complicated than I need to so, I t&lt;/FONT&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;hank you all in advance.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="helvetica"&gt;Mark&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 16 Sep 2021 20:34:44 GMT</pubDate>
    <dc:creator>MPach</dc:creator>
    <dc:date>2021-09-16T20:34:44Z</dc:date>
    <item>
      <title>SQL Select Attributes from a Table &gt; Intersect with feature &gt; remove intersecting features with Modelbuilder</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099017#M25841</link>
      <description>&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;The goal with my model is to locate features that intersect a feature class of sewer mains. After a sewer main is determined to intersect with a feature I need to remove the ability to select that feature from the list then continue. Right now I'm using a Switch Selection to select all the features that are left minus the previously selected mains, but unfortunately this idea doesn't work because if there were zero features selected during the intersect process the switch selection will result in returning the entire original table which would ruin the process of eliminating mains as I proceed down the list of features I need to intersect with.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;I'm going to try to break this down in a linear format to make it easier to understand.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" size="3"&gt;Select sewer mains that Intersect with a Buildings feature class &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Assuming there are results create a feature layer from the selection &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Perform a Switch Selection on the sewer mains table to find the remaining sewer mains &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Use the Select by location to find the intersection of the remaining sewer mains against railroad tracks &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Create a feature layer for those &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt; Repeat until through the list.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;I'm certain there are better ways to do this using Modelbuilder, but I'm mentally blocked from seeing them right now. I need some help please.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;Also, I'd like to use Modelbuilder for this and not Python right now.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;I'm pretty sure I'm making this more complicated than I need to so, I t&lt;/FONT&gt;&lt;FONT face="times new roman,times" size="4" color="#000080"&gt;hank you all in advance.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="helvetica"&gt;Mark&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Sep 2021 20:34:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099017#M25841</guid>
      <dc:creator>MPach</dc:creator>
      <dc:date>2021-09-16T20:34:44Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Select Attributes from a Table &gt; Intersect with feature &gt; remove intersecting features with Modelbuilder</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099245#M25842</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/236505"&gt;@MPach&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;This modelbuilder does what you are after if I understood your workflow correctly:&lt;/P&gt;&lt;P&gt;Make sure the first &lt;STRONG&gt;Select Layer By Location&lt;/STRONG&gt; has &lt;EM&gt;&lt;STRONG&gt;Invert spatial relationship&lt;/STRONG&gt;&lt;/EM&gt; ticked on.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MehdiPira1_4-1631844317958.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/23247iBB37724FBDF52228/image-size/medium?v=v2&amp;amp;px=400" role="button" title="MehdiPira1_4-1631844317958.png" alt="MehdiPira1_4-1631844317958.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="MehdiPira1_1-1631843886813.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/23244i0D7EE9044E72B799/image-size/large?v=v2&amp;amp;px=999" role="button" title="MehdiPira1_1-1631843886813.png" alt="MehdiPira1_1-1631843886813.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 02:05:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099245#M25842</guid>
      <dc:creator>MehdiPira1</dc:creator>
      <dc:date>2021-09-17T02:05:42Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Select Attributes from a Table &gt; Intersect with feature &gt; remove intersecting features with Modelbuilder</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099341#M25843</link>
      <description>&lt;P&gt;Hummm,&amp;nbsp; that's an interesting idea. I don't know if even saw that being an option. I have to test it first and see what happens. Thank you. Also, regardless of that solution you led me to find the Get Count tool, which I had forgotten about, and I bet I can make that work too.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 13:41:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099341#M25843</guid>
      <dc:creator>MPach</dc:creator>
      <dc:date>2021-09-17T13:41:04Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Select Attributes from a Table &gt; Intersect with feature &gt; remove intersecting features with Modelbuilder</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099719#M25847</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/236505"&gt;@MPach&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I believe the solution answered your question.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Sep 2021 00:36:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1099719#M25847</guid>
      <dc:creator>MehdiPira1</dc:creator>
      <dc:date>2021-09-20T00:36:04Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Select Attributes from a Table &gt; Intersect with feature &gt; remove intersecting features with Modelbuilder</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1100048#M25848</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/43250"&gt;@MehdiPira1&lt;/a&gt;&amp;nbsp;I'm not actually sure that solution works, but I haven't tested it yet. I think the suggested solution that you recommended might have the same flaw as the one that I first tried. That flaw being if there is no intersection of the features the table selection that will be returned would be the entire contents of the original table.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I sketched up a quick drawing of the flow to get to the solution. I hope it's legible.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I think the solution involves using a test case (If...Then....Else workflow) to see if the row count of the intersection is = 0 and then if that occurs I use the previous tables selection in the next part of my workflow. Doing that I should still be proceeding in the right direction instead of starting over with the original data table.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MPach_0-1632164965050.png" style="width: 918px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/23406i4F025E97414DB59E/image-dimensions/918x271?v=v2" width="918" height="271" role="button" title="MPach_0-1632164965050.png" alt="MPach_0-1632164965050.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Sep 2021 19:13:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/sql-select-attributes-from-a-table-gt-intersect/m-p/1100048#M25848</guid>
      <dc:creator>MPach</dc:creator>
      <dc:date>2021-09-20T19:13:28Z</dc:date>
    </item>
  </channel>
</rss>

