AnsweredAssumed Answered

Workforce 'create assignments from csv' script - no assignments symbolized on map

Question asked by on May 9, 2018
Latest reply on May 15, 2018 by

Hi all.  I have been learning and using Workforce and the various Python 'create' scripts available from GitHub.  With some excellent help from Esri staff, I had great success using a create assignment script for the Citizen Problem Reporter and Manager solutions.  I am now using 'create assignments from csv' script to automate assignment creation for hydrant flushing.  After a fair amount of trial and error, I was able to have the script create assignments (but without having the Dispatcher or Worker fields populated).  However, the maps in Workforce and Pro, do not show the assignment symbology (unassigned, assigned, in progress, etc.).  The attribute table for the assignment feature service shows the assignment records but again there are no symbols on the maps.  If I use the 'Zoom to' function for a row in the att table, we go nowhere.  I did have trouble executing the script where I had a 'string to float' error on the xField.  After checking each coordinate carefully, and still receiving the same error, I did a copy/paste of the existing csv into a new xlsx/csv file, and the error went away. The script started working and created assignments.


So I need some assistance in getting the assignment features to symbolize please.  The Shape field is populated with Point.


Also, I am stumbling on passing the Dispatchers and Workers from the csv file.  From the schema, the userid fields are text.  In looking at the att tables for both services, the userid columns are populated with our email usernames (e.g., "jhodny@newark.yadda.yadda_CityOfyadda") When I include these two columns in the csv file, I get a 'ValueError: invalid literal for int() with base 10: 'jhodny@newark.yadda.yadda_CityOfyadda' error.  I am not sure what to do here.