AnsweredAssumed Answered

How to delete a GlobalID-based relationship class

Question asked by Beibhin on Oct 31, 2017
Latest reply on Oct 31, 2017 by Beibhin

I have two feature classes (wControlValve and wBlowOff) that I need to drop and recreate weekly (part of a migration of data from Smallworld to ESRI). Once they're recreated, I create an ObjectID-based relationship class which I then migrate to a GlobalID-based relationship class. I successfully created it once. The problem is I can't delete it in order to recreate it every week!  I've tried right-clicking it and choosing "Delete" which always appears to be successful - at first - but then when I refresh, the relationship class is still there.  I also haven't been able to delete it via python (which is actually how I need to accomplish it). I've tried when everyone is off but me (as sde - see attachment), but still get the lock message. Any ideas?

 

>>> arcpy.env.workspace = "Database Connections/aoprod-sde.sde"

>>> arcpy.Exists('gis.sde.wControlValve_wBlowOff')

True

>>> arcpy.Delete_management('gis.sde.wControlValve_wBlowOff')

Runtime error Traceback (most recent call last): File "<string>", line 1, in <module> File "c:\program files (x86)\arcgis\desktop10.5\arcpy\arcpy\management.py", line 4341, in Delete raise e ExecuteError: ERROR 000601: Cannot delete Database Connections/aoprod-sde.sde\gis.sde.wControlValve_wBlowOff. May be locked by another application. Failed to execute (Delete).

>>>

Attachments

Outcomes