|
POST
|
Thank you for this information - that all makes sense and is what I suspected. I will play around with this and see if I can figure it out. I really appreciate all of your help and your learning suggestions.
... View more
05-05-2021
08:32 AM
|
0
|
0
|
3986
|
|
POST
|
@XanderBakker One additional question has come up. In my Dashboard, I have a map. I would like to set a Map Action so that all of my indicators are updated based on map extent. When I set this, my indicator changes to display "no data". Are map actions not compatible with elements configured via Data Expression?
... View more
05-05-2021
07:53 AM
|
0
|
3
|
3992
|
|
POST
|
That worked perfectly! Thank you. One question I do have...what are your recommended methods for someone to learn more about Arcade? I have taken the courses available through the Esri training catalog, but felt they left a lot to be desired. I do look at the Developer Reference for Arcade, but I find this less helpful in some instances.
... View more
05-05-2021
07:37 AM
|
0
|
1
|
3992
|
|
POST
|
@XanderBakker Ah I see. I am perplexed by my data. This was created via Pro with a named relationship class based on GlobalID/GUID, however this is what I see via the REST endpoint. I would have expected to see the relationship class name that I defined in Pro before I published these data to ArcGIS Online. Out of curiosity, I added this layer to a new map and went into the pop-up to add a new expression. I clicked through $feature like you mentioned, found related records at the bottom and then clicked FeatureSetByRelationshipName to add it into the builder window. This is what I see. FeatureSetByRelationshipName($feature,"") Here is the Arcade I attempted...I am now getting the "Unable to execute Arcade script" message again, even though it returns the correct number of records when I click "Test": var p = 'https://www.arcgis.com';
var itemID_CMpts = 'xxx';
var layerID_CMpts = 0;
var relationshipName = "";
var fs1 = Filter(FeatureSetByPortalItem(Portal(p), itemID_CMpts, layerID_CMpts, ['Point_Status', 'EQ_File_Number'], false), "Point_Status ='Unstable' AND EQ_File_Number In ('EQ2015-078', 'Eq2013-026', 'EQ2018-082', 'EQ2018-052', 'EQ2001-080X', 'EQ2003-021', 'EQ1989-015', 'EQ2002-023', 'EQ2002-045X', 'EQ2019-110', 'EQ2020-017', 'EQ2019-091', 'EQ2018-029', 'EQ2020-033', 'EQ2019-036', 'EQ2020-052', 'EQ2019-064', 'EQ2017-040', 'EQ2020-031', 'EQ2021-003', 'EQ2011-016', 'EQ2017-026', 'EQ2021-020')");
var tot = 0;
for (var f in fs1) {
var fs2 = FeatureSetByRelationshipName(f, relationshipName, ['Point_Status_revisit'], false);
var cnt = Count(fs2);
if (cnt == 0) {
tot += 1;
}
}
return tot;
... View more
05-05-2021
05:59 AM
|
0
|
7
|
11752
|
|
POST
|
I will give this a try tomorrow morning. One question...the relationship name that I put in there, is it the name of the relationship class in the fGDB from pre-publishing to AGOL?
... View more
05-04-2021
11:44 AM
|
0
|
9
|
11758
|
|
POST
|
Hi Xander, Thank you for the example. I was able to get this to work using something I came up with that basically does what you showed in the example. Unfortunately, this is not quite what I need after reflecting on the results. What I really want to be able to do is get the count of records in my point layer that do not have any related records associated with them. Is that possible using the FeatureSetByRelationshipName parameter? I've seen some other posts you have responded to around FeatureSetByRelationshipName, but none of the examples talk about doing something like what I am trying to accomplish. Thank you,
... View more
05-04-2021
09:00 AM
|
0
|
11
|
11766
|
|
POST
|
Hi, I am very new to Arcade (which you probably be able to tell by my filter expressions below). I am attempting to create a Data Expression that can be used to power an Indicator widget in a Dashboard. I have built and tested this in the Data Expression builder within my Dashboard and when I click "test" it returns the proper result. I click done, but then see a little triangle with an ! telling me "Unable to execute Arcade script". Why would I see this message? My Arcade script is below. Any help would be appreciated. var p = 'https://www.arcgis.com';
var itemID_CMpts = 'xxx';
var layerID_CMpts = 0;
var fs1 = FeatureSetByPortalItem(Portal(p), itemID_CMpts, layerID_CMpts, ['Point_Status', 'EQ_File_Number'], false);
var filterCMpts = Filter(fs1, "Point_Status ='Unstable' AND EQ_File_Number ='EQ2015-078' OR Point_Status ='Unstable' AND EQ_File_Number = 'Eq2013-026' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2018-082' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2018-052' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2001-080X' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2003-021' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ1989-015' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2002-023' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2002-045X' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2019-110' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2020-017' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2019-091' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2018-029' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2020-033' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2019-036' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2020-052' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2019-064' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2017-040' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2020-031' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2021-003' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2011-016' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2017-026' OR Point_Status ='Unstable' AND EQ_File_Number = 'EQ2021-020'");
var itemID_join = 'xxx';
var layerID_join = 0;
var fs2 = FeatureSetByPortalItem(Portal(p), itemID_join, layerID_join, ['Point_Status_revisit', 'EQ_File_Number'], false);
var filterJoin = Filter(fs2, "Point_Status_revisit ='Stable' AND EQ_File_Number ='EQ2015-078' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'Eq2013-026' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2018-082' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2018-052' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2001-080X' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2003-021' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ1989-015' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2002-023' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2002-045X' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2019-110' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2020-017' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2019-091' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2018-029' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2020-033' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2019-036' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2020-052' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2019-064' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2017-040' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2020-031' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2021-003' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2011-016' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2017-026' OR Point_Status_revisit ='Stable' AND EQ_File_Number = 'EQ2021-020'");
var CntCMpts = Count(filterCMpts)
var CntJoin = Count(filterJoin)
return CntCMpts - CntJoin Thank you!
... View more
04-28-2021
09:14 AM
|
1
|
27
|
19700
|
|
POST
|
Thank you! This was simple and elegant and worked perfectly. I really appreciate your help!
... View more
04-01-2021
11:47 AM
|
0
|
0
|
1707
|
|
POST
|
I have sent this information via email - thank you!
... View more
04-01-2021
05:17 AM
|
0
|
0
|
5542
|
|
POST
|
@ZhifangWang - I am seeing this error when attempting to generate a Summary Report now. My template uploads with no syntax errors. I can generate a sample report using 20 records, and it works perfectly. When I go to select all records (152), it fails with this generic error. I have tried this in both Firefox and Chrome with the same results. When I attempt with 130 records, it fails. When I tried it with a random number of records (56), it worked. Is there a record limitation I am not aware of when generating these reports? How would I go about identifying the issue and resolving this? This issue was not present previous when I was initially testing and building this summary report template. This is the first time I have attempted to generate a report in 2-3 weeks. This Survey also has an individual record report template associated with it, and that works without issues.
... View more
03-31-2021
10:50 AM
|
0
|
1
|
6845
|
|
POST
|
As long as your relationship is defined before publishing the data to AGOL, you should be fine and the relationship will remain. I am not sure if the GlobalID/GUID values will be the same as what you've got recorded in your local fGDB though - that's something I have never checked.
... View more
03-25-2021
05:37 AM
|
1
|
0
|
4113
|
|
IDEA
|
@FedericoRiet_Sapriza - I am way late to respond here, but in case you are still having issues, this is how I've dealt with a similar situation to what you're describing. Within a repeat I have 3 questions that could all be answered, or only one or two could be answered. Each of the 3 questions could write a value to one of ~93 unique fields depending on a previous selection. Then, to get a sum I use a series of coalesce statements within my repeat. Outside of my repeat, I then use a sum on the coalesced values. This works well and I would imagine it would also work for your mean calculation. I've included an example below. Inside Repeat (integer type): Field 1 = Violation1aFirst (called w/ relevant statement) Field 2 = Violation1aSecond (called w/ relevant statement) Field 3 = Violation1aThird (called w/ relevant statement) Inside Repeat, to get valid value (calculate type): Field = CoalesceVio1a coalesce(${Violation1aFirst},0) + coalesce(${Violation1aSecond},0) + coalesce(${Violation1aThird},0) Outside Repeat to get sum across repeats (integer type): sum(${CoalesceVio1a}) This process results in a lot of fields within my survey (all hidden based on relevance or because "calculate" type). All total, I have 526 rows in my XLS form dedicated to dealing with these calculations.
... View more
03-25-2021
05:32 AM
|
0
|
0
|
4633
|
|
BLOG
|
@DeonLengton I have a few surveys where this is also an issue. I use a scheduled Python script to handle deleting these empty records each night, and that works well enough. It would be nice if a Minimal Compact appearance did work as you've described though.
... View more
03-25-2021
05:18 AM
|
1
|
0
|
13411
|
|
POST
|
I am a bit new to using GeoEvent, so apologies if this is a silly question. I have a GeoEvent Service that is polling an ArcGIS Online feature (point) layer for changes. The end product of this Service is to generate an email notification to maintenance crews alerting them of downed trees. I am using the Add XYZ Values processor to extract the XY coordinates from the point feature in AGOL and I am sending this in the email. When I test this it works well, however my coordinates are in web mercator - not the most informative. I want to convert these coordinates into lat/long (decimal degrees). Is this possible? I've been unable to find a method for doing this. Any help or suggestions would be appreciated. Erica
... View more
03-24-2021
07:56 AM
|
0
|
2
|
1725
|
|
BLOG
|
Is it possible to set a survey to open to the most recently added repeat when a survey is being edited from the Inbox? By default, the survey opens at the first repeat added. I'd like to be able to set the survey to open at the last repeat added (the most recent).
... View more
03-10-2021
05:52 AM
|
1
|
0
|
80595
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 09-06-2022 09:14 AM | |
| 6 | 10-24-2024 12:04 PM | |
| 1 | 04-28-2021 09:14 AM | |
| 3 | 09-06-2022 11:53 AM | |
| 1 | 01-17-2024 05:18 AM |
| Online Status |
Offline
|
| Date Last Visited |
02-14-2025
01:16 PM
|