We have a GP service where the last step is to add a field (DOUBLE, holds 2 decimal places) - and does a field calculation. It's going from feet to miles - we only want to display 2 decimal places - so .34 miles instead of .34125823672... for example.
All works correctly running the tool in ArcMap - the output dataset is an in_memory feature layer, with the correct properties in the calculated miles field.
Using the tool through a GP Widget in WAB (Portal, 10.6) - the field in question displays all of the decimal places - not respecting what was set in the script.
Any way to enforce this in the Widget config (nothing obvious I could see) or tool config in arcmap?
Solved! Go to Solution.
Excellent - many thanks Jake, that does the trick.
Still curious why it displayed correctly in ArcMap running the tool, but differently when run as a GP Service, since the properties of the field is explicitly set to be 2 decimal places.
Custom GP services are fickle things.