Select to view content in your preferred language

Unregister as Versioned Throwing Schema Lock Error

167
1
Jump to solution
10-01-2024 06:19 AM
JoshBillings
Frequent Contributor

Hey all,

I have a script that I have used several times in the past to unregister feature classes as versioned. I have had no issues with this in the past. 

When I try to run the script now, I am getting a this error message:
"ERROR 000464: Cannot get exclusive schema lock. Either being edited or in use by another application or service."

The very first thing I do in the script is disconnect all users using this arcpy function

arcpy.DisconnectUser(sde_conn, "ALL")

I also double check to see if there is some user that may still be connected, but I am not seeing any through geodatabase administration in ArcGIS Pro nor is the DBA seeing anything on his side.

Is there something that I could be missing that could be hanging this up?

Thanks! - Josh

0 Kudos
1 Solution

Accepted Solutions
JoshBillings
Frequent Contributor

This was a simple mistake on my end. I had the wrong database instance in my SDE connection file. This differed from the database instance that disconnected all users. This is why I was receiving the schema lock error.

View solution in original post

1 Reply
JoshBillings
Frequent Contributor

This was a simple mistake on my end. I had the wrong database instance in my SDE connection file. This differed from the database instance that disconnected all users. This is why I was receiving the schema lock error.