POST
|
Agreed! You’re seeing that because you’re using a SEDF
... View more
11-23-2022
06:03 AM
|
0
|
0
|
572
|
POST
|
@Jay_Gregory Great question! Been wondering the same thing actually. We are running Portal in AWS on Linux machines as well. So far I've had success publishing geoprocessing services to our Server (linux) and it functioning properly. I even published one web tool that takes excel spreadsheets as input and aggregates them all together and returns it to the user. Which at first I wasn't sure would work with the server machine being Linux based but so far it's been great. Outside of that, alot of the web tools are just hitting the REST endpoints of our various services we have published in project support. Haven't explored the staged .aprx file on the Linux machine yet to see if it can still be accessed or not. Post back here if you find out any more about that!
... View more
02-04-2022
02:51 PM
|
0
|
0
|
828
|
POST
|
Like @Mannus_Etten mentioned, you can use the python sharing module. https://pro.arcgis.com/en/pro-app/latest/arcpy/sharing/mapimagesharingdraft-class.htm#C_GUID-60871391-D229-4DEB-A958-205FEB751791
... View more
10-03-2021
08:43 AM
|
0
|
0
|
592
|
POST
|
Duh! Was missing the 'result' portion. No wonder nothing was being returned. Thanks!
... View more
09-20-2021
05:58 AM
|
0
|
0
|
465
|
POST
|
Great! Yes, I think you could use the Split() function in Arcade to accomplish this? Otherwise if you have a constant number of characters then maybe a Mid()function could be used to grab it? https://developers.arcgis.com/arcade/function-reference/text_functions/#split
... View more
09-16-2021
02:23 PM
|
1
|
0
|
1080
|
POST
|
Instead of using a list to iterate over you could use the When() function in Arcade. This will let you test a series of conditional expressions. Then you can put your text logic as one of the returns for the expression(s). I would also look into the Function Reference documentation for some other helpful functions to accomplish this> https://developers.arcgis.com/arcade/function-reference/logical_functions/#when // Custom Arcade Expression for Symbology
// Test to see if "Y" is in any of the three exceedance columns. If so,the
// expression returns true and the point is symbololized as "Y". Otherwise, the expression
// returns false and the point is symbolized as "N".
// Eceedance Fields
var exc1 = $feature["As_1_Exc"]
var exc2 = $feature["As_2_Exc"]
var exc3 = $feature["As_3_Exc"]
// Testing which fields have a "Y" value and return True, else return False
var soilExceeds = When( exc1 == 'Y' || exc2 == 'Y' || exc3 == 'Y', 'Y', 'N')
//Return Values
return soilExceeds
... View more
09-16-2021
01:42 PM
|
1
|
1
|
1096
|
POST
|
@HusseinNasser2 I have a SDE database and I have a related table within the database. The table is housing records submitted from Survey123 for liquid level readings. I would like to visual some of these submitted readings, but I don't want to create a join to do so. As an alternative I have implemented an Attribute Rule for the field containing the values I would like to visual by. In another layer within my database I have added a new field in order to write the value from the table into. I have done this successfully. So when a new record is inserted in the related table, my Attribute Rule successfully executes and writes my desired value into the other layer within my database. The only issue is that the value doesn't end up in the related table. It's like the Attribute Rule is stealing it before it is finally inserted into the table. Is this expected behavior? A way to work around this? Any insight you could provide would be much appreciated! Please see my code below: //Field: toc_to_liquid_1
//Trigger: insert
//Execution: Exclude from application evaluation
//The example below is a calculation rule on a text field of a liquid level survey table.
//When a new record is inserted within the survey table the value from the text field is written into a corresponding field in the master layer
// Master layer accessed as a Feature Set
var masterLayer = FeatureSetByName($datastore,'L0RMCDemo_GIS_SDE_RMC_Demo_Master_Layer', ['globalid', 'Point_ID', 'current_liquid_level'], false);
//Extraction well point_id
var pointID = $feature['well_id'];
// Filter statement (SQL) - access variable with @
var filterStatement = 'Point_ID = @pointID';
// Filter the master layer by the filter statement - grabs the value that matches from Master to LL Table
var masterFilter = Filter(masterLayer, filterStatement);
var currentTOC = [];
for (var record in masterFilter) {
currentTOC = [{
'globalid': record.GlobalID,
'attributes': {
'current_liquid_level': $feature.toc_to_liquid_ft_1
}
}];
return {
'edit': [{
'className': 'RMCDemo_GIS.SDE.RMC_Demo_Master_Layer',
'updates': currentTOC
}]
}
}
... View more
09-16-2021
12:23 PM
|
0
|
2
|
514
|
BLOG
|
@HusseinNasser2 I have a SDE database and I have a related table within the database. The table is housing records submitted from Survey123 for liquid level readings. I would like to visual some of these submitted readings, but I don't want to create a join to do so. As an alternative I have implemented an Attribute Rule for the field containing the values I would like to visual by. In another layer within my database I have added a new field in order to write the value from the table into. I have done this successfully. So when a new record is inserted in the related table, my Attribute Rule successfully executes and writes my desired value into the other layer within my database. The only issue is that the value doesn't end up in the related table. It's like the Attribute Rule is stealing it before it is finally inserted into the table. Is this expected behavior? A way to work around this? Any insight you could provide would be much appreciated! Please see my code below: //Field: toc_to_liquid_1
//Trigger: insert
//Execution: Exclude from application evaluation
//The example below is a calculation rule on a text field of a liquid level survey table.
//When a new record is inserted within the survey table the value from the text field is written into a corresponding field in the master layer
// Master layer accessed as a Feature Set
var masterLayer = FeatureSetByName($datastore,'L0RMCDemo_GIS_SDE_RMC_Demo_Master_Layer', ['globalid', 'Point_ID', 'current_liquid_level'], false);
//Extraction well point_id
var pointID = $feature['well_id'];
// Filter statement (SQL) - access variable with @
var filterStatement = 'Point_ID = @pointID';
// Filter the master layer by the filter statement - grabs the value that matches from Master to LL Table
var masterFilter = Filter(masterLayer, filterStatement);
var currentTOC = [];
for (var record in masterFilter) {
currentTOC = [{
'globalid': record.GlobalID,
'attributes': {
'current_liquid_level': $feature.toc_to_liquid_ft_1
}
}];
return {
'edit': [{
'className': 'RMCDemo_GIS.SDE.RMC_Demo_Master_Layer',
'updates': currentTOC
}]
}
}
... View more
09-16-2021
12:10 PM
|
0
|
0
|
1236
|
POST
|
@rachelm I'm not sure about that one actually. Maybe check the API reference? One of those arguments might do the trick! https://developers.arcgis.com/python/api-reference/arcgis.apps.survey123.html
... View more
09-14-2021
05:11 PM
|
0
|
0
|
822
|
POST
|
rachelm, Try using the following code snippet. It will look through the content of the user and download anything that matched the surveyID of the report that was just generated. You'll need to define the variables 'surveyID' and 'output_folder' to match your environment. # Search for generated survey123 reports owned by the logged-in user my_content = gis.content.search(query="owner:" + gis.users.me.username, item_type="Code Sample", max_items=15) for x in my_content: if surveyID in x.description: # Get ID of each Word doc AGOL item id = x.id # Get item with matching ID data_item = gis.content.get(id) # Download each Word doc to specified location data_item.download(output_folder) # Delete item from My Content after download as it's no longer needed data_item.delete()
... View more
09-01-2021
05:31 AM
|
1
|
0
|
844
|
POST
|
Chris, I had not seen that before since I've only ever worked with 4 positional arguments at one time. The only thing that was holding mine up previously was the structure of the SQL statement for the 'where_filter'. Once I was able to get that sorted out then it worked fine for me. What did help get that sorted out was going to the 'Service URL' for the service layer I was querying for the feature report generation and using the 'Validate SQL' operation against that service. That helped me make sure my SQL statement was valid and also gave me a clue as to why it might not be working. So maybe start there? It's always good to rule things out one at a time so you know what's holding you up. Hope that helps! Here's a code sample from my working script that I ran through a Notebook in Pro from arcgis.gis import GIS from IPython.display import display gis = GIS("pro") from arcgis.apps.survey123._survey import SurveyManager, Survey survey_mgr = SurveyManager(gis) ## Set / change all variables here output_folder = "C:\\Users\\5018beh\\Downloads" # location on your local machine survey = survey_mgr.get("insert ID here") # Creating survey object using survey ID surveyID = ("insert ID here") # surveyID template = survey.report_templates[2] # Feature report template from Portal utc_offset = '+0400' # UTC offset for central time report_title = "NCLF Daily Reports" # Title that will show in S123 recent task list where_filter = "last_edited_date >= CURRENT_TIMESTAMP - INTERVAL '7' DAY" # Filter for survey submissions in the last 7 days # Generate Survey Feature Report in Survey123 survey.generate_report(template, where_filter, utc_offset, report_title)
... View more
08-11-2021
02:48 PM
|
1
|
0
|
877
|
POST
|
Chris, Not sure if this would make a difference or not but have you tried passing your where_filter variable into the survey.generate_report function as a parameter? Instead of using the SQL statement as the parameter. I would also double check your use of the "created_date" field and make sure it's the correct field both in it being a date/time object and that the name is correct. like so: where_filter = "created_date >= CURRENT_TIMESTAMP - INTERVAL '100' DAY" survey.generate_report(surveytemplate, where_filter) Also, maybe try a different day interval and see if it's the use of 100 days that's throwing it off? Maybe try 7 and see if that works? Hope this helps!
... View more
08-05-2021
07:13 AM
|
0
|
1
|
1168
|
POST
|
Drew, I was able to get the 'Where' clause to work using this syntax: "last_edited_date" was the field in my layer that I wanted to query by. This generated a report from my survey for the last 7 days successfully where_filter = "last_edited_date >= CURRENT_TIMESTAMP - INTERVAL '7' DAY" survey.generate_report(template, where_filter, "+0400", "NCLF Daily Flare Inspection")
... View more
04-23-2021
12:58 PM
|
1
|
0
|
1350
|
POST
|
It does! Just wanted to repeat in my own words too, to make sure I was understanding it. This is great, thank you so much!! I'll get it implemented and mark it as a solution once I'm able to verify it works for me. Thanks again for all your help.
... View more
04-22-2021
06:19 AM
|
0
|
0
|
2198
|
POST
|
Johannes, Just so I can be sure I'm understanding your logic here... You're creating a FeatureSet, new feature ($feature) is always the most current one, to run an 'Intersect' against the same layer to identify which locations have multiple points. For these locations you're testing the Global IDs against each other to identify which ones match the newly created FeatureSet(being the most recent). The ones that match get a '1' and the ones that don't get a '0'. Then you can use that field to hide the '0's and display the '1's. This way only the most recent records are being displayed in locations where there are multiple records? Am I understanding that correctly?
... View more
04-22-2021
05:05 AM
|
0
|
2
|
2207
|
Title | Kudos | Posted |
---|---|---|
1 | 09-16-2021 01:42 PM | |
1 | 09-16-2021 02:23 PM | |
1 | 09-01-2021 05:31 AM | |
1 | 08-11-2021 02:48 PM | |
1 | 04-23-2021 12:58 PM |
Online Status |
Offline
|
Date Last Visited |
12-09-2023
06:45 AM
|