AnsweredAssumed Answered

Append_management Not Honoring Selected Features

Question asked by JCanno on May 15, 2019
Latest reply on May 15, 2019 by Dan_Patterson

I have been trying to write a simple script to append features (currently using ArcMap 10.6) that were created in a "working" file gdb to a "master" file gdb. The feature classes have the same fields and are both in feature data-sets. The "master" generally resides on an office wide server while "working" is local. Where it goes wrong is the stand alone script copies all features in the feature class, not just the selected features. Append honors selected features when run from python in ArcMap and from the GUI tool. Also experiencing the same issue if I create an append model. 

What I have tried: "NO_TEST" and "TEST", setting the "working" gdb as the work-space, placing the file pathways directly into Append_management, placing a copy of the "master" onto my computer. I have even tried creating temp gdbs, one with the "working" feature class and one with the "master" with no change. 

Going to test this on a different computer that has ArcMap 10.7 and in ArcGIS Pro 2.3 (can't use this computer at work though) and see if I can replicate it.

import arcpy

in_feature = r"C:\\\\Working_GDBs\Central.gdb\Lands\Disposals"
out_feature = r"C:\\\\Master_GDBs\Central.gdb\Lands_Master\Lands_Disposals"

schema = "TEST"

arcpy.Append_management(in_feature, out_feature, schema, " ", " ")

print("Append Completed")

Outcomes