You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 31, 2020. It is now read-only.
Attempting: To erase all the information in a Hosted Feature Layer in AGOL and replace it with updated data from the workday.
Problem: When I run the following code below I receive no errors, however my output is incorrect. when I view my results from Python Interpreter I lose features, Why is this happening.
No matter where I run it from an .sde or a geodatabase I always 745 features and their always the same features. There is no order to the features I lose in the table, what I lose are sprinkled throughout the layer.
Yes, the new table has more then 1592 records
No, its not hitting a limit of some type b/c I am also doing this for a layer with 7270 records and yes I'm losing records here as well but only 7 lost records.
INTERPRETER
+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
Existing_PE_Mains
P:\connectionfiles\Geometric Network Base.sde\GeometricNetwork.DBO.data\GeometricNetwork.DBO.Existing_PE_Mains
{u'count': 2337} - before the update
{u'count': 1592} - after the update
+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
any help would be appreciated.
Cheers,
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
ArcREST Version 3.5.9
Python Scripter v2.6.0.0
Attempting: To erase all the information in a Hosted Feature Layer in AGOL and replace it with updated data from the workday.
Problem: When I run the following code below I receive no errors, however my output is incorrect. when I view my results from Python Interpreter I lose features, Why is this happening.
No matter where I run it from an .sde or a geodatabase I always 745 features and their always the same features. There is no order to the features I lose in the table, what I lose are sprinkled throughout the layer.
Yes, the new table has more then 1592 records
No, its not hitting a limit of some type b/c I am also doing this for a layer with 7270 records and yes I'm losing records here as well but only 7 lost records.
This is a Line Feature
CODE
for i in range(0, 4):
arcpy.AddMessage(AGOL_LayerNames[i])
print(AGOL_LayerNames[i])
arcpy.AddMessage(fc + "\" + SDE_LayerNames[i])
print(fc + "\" + SDE_LayerNames[i])
fst = featureservicetools.featureservicetools(securityinfo)
fs = fst.GetFeatureService(itemId=webmapid,returnURLOnly=False)
fl = fst.GetLayerFromFeatureService(fs=fs,layerName=AGOL_LayerNames[i],returnURLOnly=False)
print fl.query(returnCountOnly=True)
fst.DeleteFeaturesFromFeatureLayer(fl.url, '1=1')
fl.addFeatures(fc=fc + "\" + SDE_LayerNames[i] ,attachmentTable=None)
print fl.query(returnCountOnly=True)
INTERPRETER
+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
Existing_PE_Mains
P:\connectionfiles\Geometric Network Base.sde\GeometricNetwork.DBO.data\GeometricNetwork.DBO.Existing_PE_Mains
{u'count': 2337} - before the update
{u'count': 1592} - after the update
+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
any help would be appreciated.
Cheers,
The text was updated successfully, but these errors were encountered: