0

I have a hosted feature service with a related table. The layer in the feature service needs to be updated every month or so. However, the data in the related table needs to remain unchanged. Is there a pythonic way to update the layer without altering the related data? I looked at creating an .sd file with Python but I don't anticipate much success based on what testing I've done. Would deleting the layer's contents and updating through the REST be feasible when I'm dealing with +70 thousand spatial objects?

1

If I understand the question correctly, you'll need to create a separate .mxd file with nothing more than the feature you'd like to update in it. Then, from that new .mxd file, publish a feature service. After that initial push, use this python script called update-hosted-feature-service to overwrite the hosted feature service as you schedule it to run.

  • If I'm understanding the script correctly, it would update the entire feature service, which I don't want to do. I only want to update a part of the feature service, the individual layer, while leaving the table unchanged. – JCB Jun 30 '17 at 12:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.