<?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>idea Select Layer by Location — Intersect (DBMS) — Create a query layer instead of a database view in ArcGIS Pro Ideas</title>
    <link>https://community.esri.com/t5/arcgis-pro-ideas/select-layer-by-location-intersect-dbms-create-a/idi-p/1365586</link>
    <description>&lt;P&gt;&lt;EM&gt;ArcGIS Pro 2.6.8; Oracle 18c 10.7.1 EGDB; SDE.ST_Geometry:&lt;BR /&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Background:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/select-layer-by-location.htm" target="_self" rel="nofollow noopener noreferrer"&gt;Select Layer By Location (Data Management)&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;docs, the&amp;nbsp;&lt;EM&gt;Relationship Parameter — Intersect (DBMS)&amp;nbsp;&lt;/EM&gt;section says:&lt;/SPAN&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;For the&amp;nbsp;&lt;SPAN class=""&gt;Relationship&lt;/SPAN&gt;&amp;nbsp;parameter, the&amp;nbsp;&lt;SPAN class=""&gt;Intersect (DBMS)&lt;/SPAN&gt;&amp;nbsp;option may provide better performance than the&amp;nbsp;&lt;SPAN class=""&gt;Intersect&lt;/SPAN&gt;&amp;nbsp;option when using enterprise geodatabase data; however, this option is only supported under specific conditions. If all conditions are met, the spatial operation will be performed in the enterprise geodatabase database management system (DBMS) rather than on the client.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;...The user connecting to the geodatabase must have privileges to&amp;nbsp;&lt;STRONG&gt;create a view in the database&lt;/STRONG&gt;&amp;nbsp;where the feature classes are stored.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;In other words, the tool creates a database view.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bud_1-1704229549155.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90337i184CEB90C5E9B239/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bud_1-1704229549155.png" alt="Bud_1-1704229549155.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bud_0-1704229531660.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90336iD25A5557861BB7DE/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bud_0-1704229531660.png" alt="Bud_0-1704229531660.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bud_2-1704229563608.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90338i3558AF4F188DC911/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bud_2-1704229563608.png" alt="Bud_2-1704229563608.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;select "OBJECTID" from ( SELECT a.OBJECTID FROM INFRASTR.ACTIVE_TRANSPORTATION a,&lt;BR /&gt;INFRASTR.AGOL_PARKINGLOT b WHERE SDE.ST_INTERSECTS(a.SHAPE, b.SHAPE) = 1 ) esri_sql&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;The view is called&amp;nbsp;SELECTIONOUTPUTNAME&lt;SPAN&gt;.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Idea:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;It seems strange to me that we'd want to create a database view.&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;It's awkward to create a persistent database object for ad hoc analysis like this.&lt;/LI&gt;&lt;LI&gt;What if the user doesn't have CREATE VIEW privileges or doesn't want to create a view?&lt;/LI&gt;&lt;LI&gt;The user might have&amp;nbsp;CREATE VIEW privileges, but the user may not have GRANT privileges for creating a view on the feature classes. The feature classes might be owned by other owners/users.&lt;/LI&gt;&lt;LI&gt;There could be issues if multiple users use the same tool in the same EGDB workspace -- the view would get overridden by the other user.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Why not use a query layer (or some other temporary query mechanism) instead of creating a database view? A query layer would solve the issues mentioned above.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Related:&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;A href="https://community.esri.com/t5/arcgis-pro-ideas/select-layer-by-location-intersect-dbms-user/idi-p/1365481" target="_self"&gt;Select Layer by Location — Intersect (DBMS) — &lt;STRONG&gt;User-defined output database view name&lt;/STRONG&gt;&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;&lt;A href="https://community.esri.com/t5/arcgis-pro-ideas/spatial-definition-query/idc-p/1365605#M27833" target="_self"&gt;Spatial definition query&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;&lt;A href="https://community.esri.com/t5/arcgis-enterprise-questions/intended-use-case-for-select-layer-by-location/m-p/1366117/highlight/true#M38138" target="_self"&gt;Intended use case for Select Layer by Location — Intersect (DBMS)?&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
    <pubDate>Thu, 04 Jan 2024 20:35:10 GMT</pubDate>
    <dc:creator>Bud</dc:creator>
    <dc:date>2024-01-04T20:35:10Z</dc:date>
    <item>
      <title>Select Layer by Location — Intersect (DBMS) — Create a query layer instead of a database view</title>
      <link>https://community.esri.com/t5/arcgis-pro-ideas/select-layer-by-location-intersect-dbms-create-a/idi-p/1365586</link>
      <description>&lt;P&gt;&lt;EM&gt;ArcGIS Pro 2.6.8; Oracle 18c 10.7.1 EGDB; SDE.ST_Geometry:&lt;BR /&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Background:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the&amp;nbsp;&lt;/SPAN&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/tool-reference/data-management/select-layer-by-location.htm" target="_self" rel="nofollow noopener noreferrer"&gt;Select Layer By Location (Data Management)&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;docs, the&amp;nbsp;&lt;EM&gt;Relationship Parameter — Intersect (DBMS)&amp;nbsp;&lt;/EM&gt;section says:&lt;/SPAN&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;For the&amp;nbsp;&lt;SPAN class=""&gt;Relationship&lt;/SPAN&gt;&amp;nbsp;parameter, the&amp;nbsp;&lt;SPAN class=""&gt;Intersect (DBMS)&lt;/SPAN&gt;&amp;nbsp;option may provide better performance than the&amp;nbsp;&lt;SPAN class=""&gt;Intersect&lt;/SPAN&gt;&amp;nbsp;option when using enterprise geodatabase data; however, this option is only supported under specific conditions. If all conditions are met, the spatial operation will be performed in the enterprise geodatabase database management system (DBMS) rather than on the client.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;...The user connecting to the geodatabase must have privileges to&amp;nbsp;&lt;STRONG&gt;create a view in the database&lt;/STRONG&gt;&amp;nbsp;where the feature classes are stored.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;In other words, the tool creates a database view.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bud_1-1704229549155.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90337i184CEB90C5E9B239/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bud_1-1704229549155.png" alt="Bud_1-1704229549155.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bud_0-1704229531660.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90336iD25A5557861BB7DE/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bud_0-1704229531660.png" alt="Bud_0-1704229531660.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Bud_2-1704229563608.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90338i3558AF4F188DC911/image-size/large?v=v2&amp;amp;px=999" role="button" title="Bud_2-1704229563608.png" alt="Bud_2-1704229563608.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;select "OBJECTID" from ( SELECT a.OBJECTID FROM INFRASTR.ACTIVE_TRANSPORTATION a,&lt;BR /&gt;INFRASTR.AGOL_PARKINGLOT b WHERE SDE.ST_INTERSECTS(a.SHAPE, b.SHAPE) = 1 ) esri_sql&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;The view is called&amp;nbsp;SELECTIONOUTPUTNAME&lt;SPAN&gt;.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Idea:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;It seems strange to me that we'd want to create a database view.&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;It's awkward to create a persistent database object for ad hoc analysis like this.&lt;/LI&gt;&lt;LI&gt;What if the user doesn't have CREATE VIEW privileges or doesn't want to create a view?&lt;/LI&gt;&lt;LI&gt;The user might have&amp;nbsp;CREATE VIEW privileges, but the user may not have GRANT privileges for creating a view on the feature classes. The feature classes might be owned by other owners/users.&lt;/LI&gt;&lt;LI&gt;There could be issues if multiple users use the same tool in the same EGDB workspace -- the view would get overridden by the other user.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Why not use a query layer (or some other temporary query mechanism) instead of creating a database view? A query layer would solve the issues mentioned above.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Related:&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;A href="https://community.esri.com/t5/arcgis-pro-ideas/select-layer-by-location-intersect-dbms-user/idi-p/1365481" target="_self"&gt;Select Layer by Location — Intersect (DBMS) — &lt;STRONG&gt;User-defined output database view name&lt;/STRONG&gt;&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;&lt;A href="https://community.esri.com/t5/arcgis-pro-ideas/spatial-definition-query/idc-p/1365605#M27833" target="_self"&gt;Spatial definition query&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;&lt;A href="https://community.esri.com/t5/arcgis-enterprise-questions/intended-use-case-for-select-layer-by-location/m-p/1366117/highlight/true#M38138" target="_self"&gt;Intended use case for Select Layer by Location — Intersect (DBMS)?&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Thu, 04 Jan 2024 20:35:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-ideas/select-layer-by-location-intersect-dbms-create-a/idi-p/1365586</guid>
      <dc:creator>Bud</dc:creator>
      <dc:date>2024-01-04T20:35:10Z</dc:date>
    </item>
  </channel>
</rss>

