POST
|
If this is a bug then feel free to report it to Esri or post the issue. It also depends if the version of field maps is enterprise vs agol where the agol is more up to date.
... View more
Thursday
|
0
|
1
|
78
|
POST
|
Hi @JoseSanchez, Are you referring to using geofences, if so, then there are workflows that incorporate arcade and the creation of geometries to use as geofences when editing. You can also change the settings in field maps to collect at the current location.
... View more
Wednesday
|
0
|
7
|
168
|
POST
|
As someone who also does SQL querying in SQL server you can rename a shape field to any name you want in SQL. As to why the default is what it is nobody truly knows. My only thoughts are that it is the variation in database types since SQL has mulitple variants such as PostgreSQL, MySQL, OracleSQL, and SQL Server. I think geodatabases are a stem of what are considered Microsoft Access Databases but are created to have local shapefields. As @CalvinHarmin pointed out, using the SHAPE@ should be used in python since I believe it is catchall regarding any shape field.
... View more
a week ago
|
0
|
0
|
213
|
POST
|
Like @George_Thompson said, those names cannot be renamed. However, when it comes to using any programming language, you can create a dictionary of mapped field names. For example ( { Shape_Area: ST_AREA } ) so when you change data sources you can get the equivalent field that you need and vice versa.
... View more
2 weeks ago
|
0
|
0
|
329
|
POST
|
Here is what I came up with but without having any sample data it is the best that I could do. This is just a suggestive means but feel free to modify and ask any further questions. function RoundN(val){ iif( TypeOf(Number(val))=='Number', Round(Number(val)), 0 ) }
function Risk(n){ iif( Number(n)>0, Round(n/10)*10, 0 ) }
function ordinal(n) {
var r = n % 10
var t = When( r==1, "st", r==2, "nd", r==3, "rd", "th" )
iif( !IsEmpty(n), Concatenate(n,t), null )
}
// Set the default values
var RootFieldNames = [
"TEETHLOST","ARTHRITIS","CANCER","COPD",
"CHD","CASTHMA","DEPRESSION","DIABETES",
"BPHIGH","HIGHCHOL","OBESITY","STROKE"
]
// Set the coomon names for all fields
var RootName = 'CDC_PLACES_2175'
var percName = '_percentile'
var popName = '_EstPop'
// Creates a new line
var nl = TextfFormatting.NewLine
/* Get all attributes in the feature
Loop through and populate the dictionary */
Expects($feature,'*')
var Values = {}
for( var i in $feature ){ Values[i] = $feature[i] }
/* Another option
Expects($feature)
var Values = Dictionary($feature).attributes */
/* Create the dictionaries to be populated
using the information gathered below */
var Convert = {}
var PopVals = {}
var PCTVals = {}
for( var r in RootFieldNames ){
r = RootFieldNames[r]
var pctname = RootName + '.' + r + PercFName
var popname = r+PopFName
//Get the field name and round if the field is in the
if( HasKey(pctname,Values) ){ PCTVals[r] = RoundN(Values[pctname]) }
else if( HasKey(popname,Values) ){ PopVals[r] = PCTVals[r] = Values[popname] }
//Populate the conversion dictionary with the default values
Convert[r] = When(
r=="TEETHLOST","All teeth lost",
r=="CANCER","Cancer (non-skin) or melanoma",
r=="CHD","Coronary heart disease",
r=="CASTHMA","Coronary heart disease",
r=="CHD","Current asthma",
Includes(["ARTHRITIS","DEPRESSION","DIABETES","OBESITY","STROKE"],r),Proper(r),
r=="BPHIGH","High blood pressure",
r=="HIGHCHOL","High cholesterol",
r=="COPD", r,
null
)
}
// Set the score and limit dictionary
var Limits = { VeryHigh:[], High:[], Medium:[] }
var PctScores = { VeryHigh:[], High:[], Medium:[] }
// Loop through all keys in the conversion dictionary
for( var i in Convert ){
var pop = PopVals[i]
var pct = PCTVals[i]
// Set value dictionary with the default value
var Def = { label: Convert[i], score: pct, estPop: pop }
// Get the rating of the measured risk percentage
var R = When( Risk(pct)==90, 'VeryHigh', Risk(pct)==80, 'High', Risk(pct)==70, 'Medium', Null )
/* If the rating is a key value in the limit dictionary
then populate both the limit dictionary with the
default value and the percentage score array with the
percentages */
if( HasKey(Limits,R) ){
Push( Limits[R], Def )
Push( PctScores[R], pct )
}
}
// Set the html array
var HTMLText = []
// Loop through the limit dictionary
for( var l in Limits ){
var vals = Limits[l]
if( Count(vals) > 0 ){
// Get the score array and sort from highest to lowest of distinct values
var valscores = Reverse( Sort( Distinct( PctScores[l] ) ) )
// Set the html text
var html = "<b>"+l+" (" + Count(vals) + "):</b>"+nl
/* Set the empty paragraph html array
Loop through the array of score values and
reassign the index as the value */
var pHTML = []
for( var i in valscores ){
i = valscores[i]
// Loop through the array of score values and reassign the index as the value
for( var v in vals ){
v = vals[v]
/* If the score matches the value
update the paragraph html array with the text
erase the value from the array
break the loop */
if( v.score == i ){
var Text = '<p>style="text-indent:15%">' + Proper(v.label) + " (" + ordinal(v.score) + " Percentile and Est Pop: " + v.estPop + ")</p>"
Push( pHTML, Text )
Erase(vals,v)
break
}
}
}
/* If the count of the array below is greater than 0
then conatenate the list of values and insert a new line */
if( Count( pHTML ) > 0 ){
pHTML = Concatenate(pHTML,nl)
Push(HTMLText, html+pHTML)
}
}
else{ Console('There were no risks in this catergory') }
}
/* Return the concatenated html if the count of the html list
is greater than 0, otherwise return the default text */
iif( Count(HTMLText) > 0, Concatenate(HTMLText,nl), "No conditions at Medium or above" )
... View more
2 weeks ago
|
1
|
0
|
138
|
POST
|
There are also, in addition to what @HaydenWelch mentioned, there are a few ways in which your code can be rewritten to be simpler. Utilize the When function when there are multiple if-if else statements. The when function behaves in a similar manner and ultimately returns the same thing. You can specify the default value as null to basically do nothing if none of the when conditions are met. When there are multiple values being made but logically are the same then it is best to create a dictionary of those values rather than resulting to multiple statements. You can also use the example below in conjunction with Expects. Expects($feature)
var Values = {}
for( var i in $feature ){ Values[i] = $feature[i] }
/* Another option
Expects($feature)
var Values = Dictionary($feature).attributes
*/ Just for fun I am trying to rewrite your code for suggestive purposes.
... View more
3 weeks ago
|
1
|
1
|
198
|
POST
|
Actually if you pull up the attributes rather than the tables themselves then you will see the related records, both forward and backward.
... View more
3 weeks ago
|
1
|
0
|
177
|
POST
|
I just checked a little while ago and I am testing your method. I have never used this method before but I will give an update when things start to go in the direction that we are striving for. Thank you very much for that needed information.
... View more
3 weeks ago
|
0
|
0
|
335
|
POST
|
Does your method work in a 10.9.1 portal? I am testing it out now to see but we are unfortunately limited until we can upgrade.
... View more
3 weeks ago
|
0
|
0
|
337
|
POST
|
Just to clarify, I can write back to the original service that the survey was generated from without having it simply write to a hosted service when the survey is submitted. When I read through the documentation, I didn't see anywhere where it mentioned writing back to a feature service. I am working use a service published from an sde database. I probably should have clarified that in my question.
... View more
3 weeks ago
|
0
|
1
|
346
|
POST
|
Simple question, Can you use Survey123 to update attributes in an existing feature service or is that strictly field maps and web editing? The reason for asking is our current 10.9.1 version for portal is limited in terms of web editing and field maps currently doesn't support web editing. We are working on a complex workflow using a polygon features with related tables and the form editing capabilities in our current version leaves very little.
... View more
3 weeks ago
|
0
|
7
|
396
|
POST
|
Hi @markovic_m, Try one of the following to see if these could potentially fix your issue. Change the setting to automatically select related records on the related table. Check to see if the data in the related table matches the record in the point layer. If there isn't a match then that could be the reason. Check the message propagation of the relationship class.
... View more
3 weeks ago
|
2
|
0
|
251
|
POST
|
The code above works regardless so long as the data type is numeric. Just FYI.
... View more
3 weeks ago
|
0
|
0
|
116
|
POST
|
Hi @SanchezNuñez, You cannot include a grouping of clauses in a map filter. However, you can set it up so that it looks like the example below. ProjectStatus = Active AND ProjectLocation Includes( *Selected Values)
... View more
08-07-2025
08:49 AM
|
2
|
0
|
182
|
POST
|
Hi @CASSIEANGERER, Field maps can do calculations on hosted services and Survey123 can do it also for hosted services. Bear in mind that should the service change or the field map or survey gets reconfigured that the calculation may be lost.
... View more
08-02-2025
05:19 PM
|
0
|
0
|
169
|
Title | Kudos | Posted |
---|---|---|
1 | 2 weeks ago | |
1 | 3 weeks ago | |
1 | 3 weeks ago | |
2 | 3 weeks ago | |
2 | 08-07-2025 08:49 AM |
Online Status |
Offline
|
Date Last Visited |
Thursday
|