<?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 Re: Boolean Value from Intersects in Arcade in ArcGIS Online Questions</title>
    <link>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143347#M44337</link>
    <description>&lt;P&gt;That's interesting&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/119500"&gt;@KimberlyGarbade&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Glad you got that to work! That also worked for me. Wondering if the issue on my side may have been that the polygon layer I'm using has multiple polygon features. Even though it is filtered to only one polygon feature in the map, you must still have to query for the specific feature to use for the intersect?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="GeomConst2.JPG" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33778iCD945D9C70078006/image-size/medium?v=v2&amp;amp;px=400" role="button" title="GeomConst2.JPG" alt="GeomConst2.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;Peter &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 11 Feb 2022 21:58:55 GMT</pubDate>
    <dc:creator>PeterDalrymple</dc:creator>
    <dc:date>2022-02-11T21:58:55Z</dc:date>
    <item>
      <title>Boolean Value from Intersects in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143172#M44326</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;Can anyone provide any examples or an explanation of how to get a Boolean output rather than a FeatureSet output from the Intersects() or Within() functions? The documentation doesn't elaborate much on this and states that the function provides a Boolean output. The goal for me would be to get an Boolean value for the spatial relationship between features without having to use the Count() function as is shown in many other posts.&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example, I would think this expression would work, but it doesn't.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;IIF(Intersects(geom1, geom2), "In", "Out")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Neither does this (always returns false):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var myValue = Intersects(geom1, geom2)

IIF(myvalue == true, "In", "Out")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If I cast the intersects output as a Boolean, it is always false.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;IIF(Boolean(Intersects(geom1, geom2)), "In", "Out")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are a couple other expression patterns I've tried, but the only thing that works is to count the number of features returned in the FeatureSet and return values based upon the number of features returned.&lt;/P&gt;&lt;P&gt;I have met with a few people recently who had the same issue so it seems like a fairly common question.&lt;/P&gt;&lt;P&gt;Thanks in advance!&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;</description>
      <pubDate>Fri, 11 Feb 2022 17:57:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143172#M44326</guid>
      <dc:creator>PeterDalrymple</dc:creator>
      <dc:date>2022-02-11T17:57:16Z</dc:date>
    </item>
    <item>
      <title>Re: Boolean Value from Intersects in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143223#M44329</link>
      <description>&lt;P&gt;I too have recently encountered this with the Within fucntion returning a feature set and not a boolean as expected from the documentation:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="KristinJudy_0-1644604807219.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33746i7D41E1856E15E346/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KristinJudy_0-1644604807219.png" alt="KristinJudy_0-1644604807219.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="KristinJudy_1-1644604818329.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33747i589ADBD3A98F2152/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KristinJudy_1-1644604818329.png" alt="KristinJudy_1-1644604818329.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Some input from Esri on this would be much appreciated.&lt;/P&gt;</description>
      <pubDate>Fri, 11 Feb 2022 18:42:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143223#M44329</guid>
      <dc:creator>KristinJ</dc:creator>
      <dc:date>2022-02-11T18:42:18Z</dc:date>
    </item>
    <item>
      <title>Re: Boolean Value from Intersects in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143249#M44331</link>
      <description>&lt;P&gt;Note Intersects return a &lt;STRONG&gt;featureset&lt;/STRONG&gt;&amp;nbsp;instead of a boolean if a featureset is the input of parameter 1. See documentation &lt;A href="https://developers.arcgis.com/arcade/function-reference/geometry_functions/#geometryinputfeature---geometry" target="_self"&gt;here&lt;/A&gt;&amp;nbsp;. To output a boolean you would need to input a geometry. I cannot tell how geom1 is constructed for &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/158810"&gt;@PeterDalrymple&lt;/a&gt;&amp;nbsp;, but FeatureSetById in your example definitely returns a featureset and will hence return a featureset as well when used as input for Intersects&lt;/P&gt;</description>
      <pubDate>Fri, 11 Feb 2022 19:17:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143249#M44331</guid>
      <dc:creator>HuubZwart</dc:creator>
      <dc:date>2022-02-11T19:17:09Z</dc:date>
    </item>
    <item>
      <title>Re: Boolean Value from Intersects in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143284#M44335</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/112531"&gt;@HuubZwart&lt;/a&gt;&amp;nbsp;, thanks for your response! Is this what you're referring to? This is still returning a FeatureSet object for me.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="GeomConst.JPG" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33761i257DCF01BAC2BD1C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="GeomConst.JPG" alt="GeomConst.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thanks again!&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Feb 2022 20:05:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143284#M44335</guid>
      <dc:creator>PeterDalrymple</dc:creator>
      <dc:date>2022-02-11T20:05:41Z</dc:date>
    </item>
    <item>
      <title>Re: Boolean Value from Intersects in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143301#M44336</link>
      <description>&lt;P&gt;Finally got it to work in a popup.&amp;nbsp; I tried 15 ways and it finally worked when I returned a single feature and used the feature's geometry.&lt;/P&gt;&lt;P&gt;This is code in a popup&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="KimGarbade_0-1644611743664.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33764i4CA5AC56E9094A21/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KimGarbade_0-1644611743664.png" alt="KimGarbade_0-1644611743664.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="KimGarbade_1-1644611986407.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33766iD9A2F2CDDF3CABF7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KimGarbade_1-1644611986407.png" alt="KimGarbade_1-1644611986407.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="KimGarbade_2-1644612038441.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33767iC5070C19D9BF590F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="KimGarbade_2-1644612038441.png" alt="KimGarbade_2-1644612038441.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Feb 2022 20:41:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143301#M44336</guid>
      <dc:creator>KimberlyGarbade</dc:creator>
      <dc:date>2022-02-11T20:41:13Z</dc:date>
    </item>
    <item>
      <title>Re: Boolean Value from Intersects in Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143347#M44337</link>
      <description>&lt;P&gt;That's interesting&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/119500"&gt;@KimberlyGarbade&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Glad you got that to work! That also worked for me. Wondering if the issue on my side may have been that the polygon layer I'm using has multiple polygon features. Even though it is filtered to only one polygon feature in the map, you must still have to query for the specific feature to use for the intersect?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="GeomConst2.JPG" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/33778iCD945D9C70078006/image-size/medium?v=v2&amp;amp;px=400" role="button" title="GeomConst2.JPG" alt="GeomConst2.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;Peter &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Feb 2022 21:58:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/boolean-value-from-intersects-in-arcade/m-p/1143347#M44337</guid>
      <dc:creator>PeterDalrymple</dc:creator>
      <dc:date>2022-02-11T21:58:55Z</dc:date>
    </item>
  </channel>
</rss>

