<?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: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually? in ArcGIS Online Questions</title>
    <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136939#M43924</link>
    <description>&lt;P&gt;Thanks &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/1108"&gt;@XanderBakker&lt;/a&gt;.&amp;nbsp; Unfortunately, I don't see the $datastore option.&amp;nbsp; All I am seeing are the fields within this specific dataset.&amp;nbsp; To clarify though, I am...&lt;/P&gt;&lt;P&gt;-Trying to use Intersects in a web map pop up for an address point layer, based on what inspector zone a point falls in.&lt;/P&gt;&lt;P&gt;-Building in the pop up expression builder.&lt;/P&gt;&lt;P&gt;-Said address points and inspector zones are present in the same AGS map service (not AGO feature layer) and the entire map service has been added to the web map.&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="AdamGebhart_0-1643128817321.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/32241iB357A46BA429828D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AdamGebhart_0-1643128817321.png" alt="AdamGebhart_0-1643128817321.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I did try it where I replaced $map with $datastore (but no other changes) and that didn't work.&amp;nbsp; Do you have an idea of how that full expression should look?&lt;/P&gt;</description>
    <pubDate>Tue, 25 Jan 2022 16:44:09 GMT</pubDate>
    <dc:creator>AdamGebhart</dc:creator>
    <dc:date>2022-01-25T16:44:09Z</dc:date>
    <item>
      <title>Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1099032#M42197</link>
      <description>&lt;P&gt;Is it possible to set up an Arcade expression with the intersect function that references another layer within the same service as the features in which the expression is applied?&amp;nbsp; Or, do you have to add each endpoint within the service individually in order to make the expression work?&lt;/P&gt;&lt;P&gt;For example, I have a service with three layers: address points, food inspector zones, and watershed inspector zones.&amp;nbsp; &lt;U&gt;If I add each of the endpoints individually&lt;/U&gt;, the following expression (in the address points) returns the desired value (from the food inspector zone layer):&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AdamGebhart_0-1631816860005.png" style="width: 551px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/23171iC9E42B1F21577D2A/image-dimensions/551x124?v=v2" width="551" height="124" role="button" title="AdamGebhart_0-1631816860005.png" alt="AdamGebhart_0-1631816860005.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;However, if I add the whole service to my map and set up the same expression on the address points there it does NOT work.&amp;nbsp; I get this error:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AdamGebhart_1-1631817031312.png" style="width: 515px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/23172i09AF06D92828D9D0/image-dimensions/515x88?v=v2" width="515" height="88" role="button" title="AdamGebhart_1-1631817031312.png" alt="AdamGebhart_1-1631817031312.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Does it simply not work within a service?&amp;nbsp; Or do I have a wrong parameter?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Sep 2021 18:35:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1099032#M42197</guid>
      <dc:creator>AdamGebhart</dc:creator>
      <dc:date>2021-09-16T18:35:14Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136596#M43896</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/1108"&gt;@XanderBakker&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi Xander.&amp;nbsp; Is there any chance you can answer my question above?&amp;nbsp; Can I set up an expression in my address points that includes the intersection function, and have that be based on one of the polygon features in the layers above it?&amp;nbsp; Note, all three items are published in one map service.&amp;nbsp; I can't get it to work this way but can when I add each endpoint individually... which isn't really feasible in the grand scheme of the web map and WAB app.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AdamGebhart_0-1643057903505.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/32150i5E8D9E47D4D22ECB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AdamGebhart_0-1643057903505.png" alt="AdamGebhart_0-1643057903505.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jan 2022 21:02:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136596#M43896</guid>
      <dc:creator>AdamGebhart</dc:creator>
      <dc:date>2022-01-24T21:02:03Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136898#M43921</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/15176"&gt;@AdamGebhart&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;So you have a group layer in your (classic 3.x) web map and the Arcade expression I assume you are configuring in the pop-up. Is that correct?&lt;/P&gt;&lt;P&gt;When you want to access data in the map, I would suggest using the expression builder. There are two easy ways of assessing the data in the map, one is using $map that is creating problems, but since the data has the same datastore, you could try and use $datastore and see if that works. In the interface you can click on the arrow pointing to the right ("&amp;gt;") next to "$datastore" and navigate to the layers in the same datastore as your feature.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="XanderBakker_0-1643125697473.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/32224i3AB93036575C86ED/image-size/medium?v=v2&amp;amp;px=400" role="button" title="XanderBakker_0-1643125697473.png" alt="XanderBakker_0-1643125697473.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;this will list the layers (rest endpoints in the same service) and select the ones you need for the expression:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="XanderBakker_1-1643125732052.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/32225i3FF941C3237BFFAD/image-size/medium?v=v2&amp;amp;px=400" role="button" title="XanderBakker_1-1643125732052.png" alt="XanderBakker_1-1643125732052.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;If you have any problems, let me know.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 15:49:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136898#M43921</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2022-01-25T15:49:41Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136939#M43924</link>
      <description>&lt;P&gt;Thanks &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/1108"&gt;@XanderBakker&lt;/a&gt;.&amp;nbsp; Unfortunately, I don't see the $datastore option.&amp;nbsp; All I am seeing are the fields within this specific dataset.&amp;nbsp; To clarify though, I am...&lt;/P&gt;&lt;P&gt;-Trying to use Intersects in a web map pop up for an address point layer, based on what inspector zone a point falls in.&lt;/P&gt;&lt;P&gt;-Building in the pop up expression builder.&lt;/P&gt;&lt;P&gt;-Said address points and inspector zones are present in the same AGS map service (not AGO feature layer) and the entire map service has been added to the web map.&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="AdamGebhart_0-1643128817321.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/32241iB357A46BA429828D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="AdamGebhart_0-1643128817321.png" alt="AdamGebhart_0-1643128817321.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I did try it where I replaced $map with $datastore (but no other changes) and that didn't work.&amp;nbsp; Do you have an idea of how that full expression should look?&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 16:44:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136939#M43924</guid>
      <dc:creator>AdamGebhart</dc:creator>
      <dc:date>2022-01-25T16:44:09Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136946#M43925</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/15176"&gt;@AdamGebhart&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;So the limitation might be in the way the service is added to the map. Would it be possible to have access to the map to have a look? You could share it with a group and invite me to that group using "xbakker.spx".&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 16:54:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136946#M43925</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2022-01-25T16:54:40Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136960#M43926</link>
      <description>&lt;P&gt;Just sent the invite, thank you.&amp;nbsp; At the top of the map contents you'll see an address point layer and food and watershed inspector layers.&amp;nbsp; Each of those is an item within a larger map service (see said map service below them in the contents) and have been added as individual items to this map.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can get the expression to work when the individual instance of the address points is used, but not when attempting to do it purely in the map service list.&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 17:19:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136960#M43926</guid>
      <dc:creator>AdamGebhart</dc:creator>
      <dc:date>2022-01-25T17:19:37Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136973#M43927</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/15176"&gt;@AdamGebhart&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for sharing the map. However, I don't seem to have access to the services, so I can't really do anything at the moment. I can have a look at some of the sample Enterprise/ArcGIS Server services to see if I can replicate the situation. What version do you have for your Enterprise implementation?&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 17:33:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136973#M43927</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2022-01-25T17:33:59Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136974#M43928</link>
      <description>&lt;P&gt;Can you view this in a web map?&lt;/P&gt;&lt;P&gt;&lt;A href="https://gis.johnsoncountyiowa.gov/arcgis/rest/services/PH_Inspect/MapServer" target="_blank"&gt;https://gis.johnsoncountyiowa.gov/arcgis/rest/services/PH_Inspect/MapServer&lt;/A&gt;&lt;/P&gt;&lt;P&gt;It's a different service, but the same three datasets I'm referencing in that map.&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 17:37:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1136974#M43928</guid>
      <dc:creator>AdamGebhart</dc:creator>
      <dc:date>2022-01-25T17:37:39Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137023#M43931</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/15176"&gt;@AdamGebhart&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;I continued with a map service (group layer)&amp;nbsp; from a sample server and this is what I got:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;You are completely right that when adding a map service to the map, it will not provide access to the different layers in the same service.&amp;nbsp;&lt;/LI&gt;&lt;LI&gt;I thought that maybe the using the FeatureSetByPortalItem could be used. However, the layer is not a portal item in my portal&lt;/LI&gt;&lt;LI&gt;To overcome this aspect I added a new item to my portal by referencing the map service. This provided the portal item ID that I need to access the other layers within the grouplayer&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Below you can see the classic web map with a group layer (map service: &lt;A href="https://sampleserver6.arcgisonline.com/arcgis/rest/services/Military/MapServer" target="_blank"&gt;https://sampleserver6.arcgisonline.com/arcgis/rest/services/Military/MapServer&lt;/A&gt;) and the pop-up on the polygon areas show information from the intersecting units:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="XanderBakker_0-1643136450607.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/32262i4A80160A453A70A3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="XanderBakker_0-1643136450607.png" alt="XanderBakker_0-1643136450607.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here's the expression I used:&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var spx = Portal('https://utility-esri-co.maps.arcgis.com');
var mili = FeatureSetByPortalItem(spx, 'e5cfe3e339394ffb82270e3791a32b6a', 2);

var fsint = Intersects(mili, $feature);
var result = "";
if (Count(fsint)&amp;gt;0) {
    result = "Found " + Count(fsint) + " intersecting features:";
    for (var f in fsint) {
        result += TextFormatting.NewLine + " - " + f["SymbolName"];
    }
} else {
    result = "No intersection";
}

return result;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 18:53:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137023#M43931</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2022-01-25T18:53:47Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137027#M43932</link>
      <description>&lt;P&gt;... and just tried, but I don't have access to the rest service you provided.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jan 2022 18:54:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137027#M43932</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2022-01-25T18:54:59Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137656#M43968</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/1108"&gt;@XanderBakker&lt;/a&gt;Thanks for checking further into that.&amp;nbsp; Your example includes an ESRI service example, right?&amp;nbsp; Should I be able to use my own REST services (published with Server) with some tweaks to your expression?&lt;/P&gt;&lt;P&gt;I'm surprised you can't access the services as they're public.&lt;/P&gt;</description>
      <pubDate>Wed, 26 Jan 2022 22:00:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137656#M43968</guid>
      <dc:creator>AdamGebhart</dc:creator>
      <dc:date>2022-01-26T22:00:02Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137676#M43969</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/15176"&gt;@AdamGebhart&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;You should be able to use the code after you create the item in your portal (this is just a reference to the data). You will have to change the ItemID to the one you create and the field and logic you want to apply after accessing the layer.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I think the reason that I cannot access the website, is since it blocks access from Colombia:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="XanderBakker_0-1643236118375.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/32419i1F2C7BE69951BE87/image-size/medium?v=v2&amp;amp;px=400" role="button" title="XanderBakker_0-1643236118375.png" alt="XanderBakker_0-1643236118375.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 26 Jan 2022 22:29:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1137676#M43969</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2022-01-26T22:29:47Z</dc:date>
    </item>
    <item>
      <title>Re: Can intersect be used within one service (in a web map) or do the endpoints have to be added individually?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1139579#M44072</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/1108"&gt;@XanderBakker&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your help.&amp;nbsp; I haven't been able to try this yet will get around to eventually.&lt;/P&gt;&lt;P&gt;Regarding the Colombia thing - are you in Colombia?&amp;nbsp; Or is it saying my connection is in Colombia?&amp;nbsp; I'm in the US.&lt;/P&gt;</description>
      <pubDate>Tue, 01 Feb 2022 21:13:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/can-intersect-be-used-within-one-service-in-a-web/m-p/1139579#M44072</guid>
      <dc:creator>AdamGebhart</dc:creator>
      <dc:date>2022-02-01T21:13:46Z</dc:date>
    </item>
  </channel>
</rss>

