Geoprocessing Service Scratch.gdb to SDE

246
1
Jump to solution
12-10-2019 03:17 PM
EddyClark
New Contributor III

I'm using model builder because tracing a geometric network on python is a pain.  In my last Tool (Copy Features) the original model copies the Input data to SDE.  However when used in a Geoprocessing Service it processes the Copy into the Scratch.gdb. 

How do I get it to Copy Features to SDE like the original model?

Here is the message.xml from the server

<MessageDesc>Executing (Copy Features (2)): CopyFeatures c:\arcgisserver\directories\arcgisjobs\outage\traceswitchoutage_gpserver\j920ae311f6df4a89a8f4fcca52ce96a4\scratch\GDBO_Buffer_Dissolve.shp c:\arcgisserver\directories\arcgisjobs\outage\traceswitchoutage_gpserver\j920ae311f6df4a89a8f4fcca52ce96a4\scratch\scratch.gdb\PubPow.GDBO.SwitchOutage # 0 0 0</MessageDesc></GPMessage>

Here is a snapshot of the model, with the last tool (Copy Features (2)) open.

0 Kudos
1 Solution

Accepted Solutions
JonathanQuinn
Esri Frequent Contributor

From my experiences, GP services will always update the paths for output data to point to the scratch GDB rather than their original locations since it can't guarantee it can write to the original location. Also, that path may be over a network and the GP framework prioritizes speed and throughput, so it'll write locally anyway:

Geoprocessing service settings: Parameters—Documentation | ArcGIS Enterprise 

What you can look into is truncating the table/feature class in the geodatabase and then appending the records to it.

Truncate Table—Data Management toolbox | ArcGIS Desktop 

Append—Data Management toolbox | ArcGIS Desktop 

View solution in original post

0 Kudos
1 Reply
JonathanQuinn
Esri Frequent Contributor

From my experiences, GP services will always update the paths for output data to point to the scratch GDB rather than their original locations since it can't guarantee it can write to the original location. Also, that path may be over a network and the GP framework prioritizes speed and throughput, so it'll write locally anyway:

Geoprocessing service settings: Parameters—Documentation | ArcGIS Enterprise 

What you can look into is truncating the table/feature class in the geodatabase and then appending the records to it.

Truncate Table—Data Management toolbox | ArcGIS Desktop 

Append—Data Management toolbox | ArcGIS Desktop 

View solution in original post

0 Kudos