The .gbd I am working with is locked and when I attempt to add a field I get a message stating "cannot acquire schema lock because of an existing lock". Thx
The feature class in the File Geodatabase is being used by another user. If no users are accessing the geodatabase, make sure the feature class does not participate in a service that is running. If it does, you will need to stop the service in order to update the schema.
The Feature Class is not open by other users while attempting to add a field. The gdb is on a shared network and some other users do have older versions of ArcMap so its possible that those could be issues but not 100%.
Does the lock have the current time or is it an old time?
I have file gdbs that have multiple locks where 1 is the current lock and the other locks are there because ArcMap might have crashed in the past while someone or an ArcGIS Server service was accessing the file gdb when it crashed. I was able to delete the older locks, but the current lock could not be deleted as it indicated that the file gdb was in use.
If the feature class is in a File or Personal Geodatabase and you still get the lock even after checking that it is not being used, there is another solution to clearing the lock. Here's what you do - run the Compact (Data Management) Tool. ESRI Support passed this on to me when I had a similar issue several months ago with File Geodatabases showing as locked even though no one else was using them. Compact will resolve the locks as it has a built in process to clear locks as part of it's running. To be clear, the Compact tool is being run for the desirable side effect of lock-clearing, not because compaction (or lack of) has anything to do with causing the locks.
Note to avoid potential confusion - the Compact geoprocessing tool needs to be run, not the Administration - Compact Database process from ArcCatalog, which sound like it is the same (but is not), as the latter process does not have the lock-clearing functionality.
ArcGIS Help 10.2 - Compact (Data Management)
Chris Donohue, GISP
I will try to use the compact tool once Im done exporting this monster gdb to my hard drive. I believe it is good practice to compact large gdb's as it is. Thanks!
Another solution is to use a utility like Unlocker. It also helps during ArcPy debugging sessions when locks persist.
"Uncompress" (even though results stated that gdb had already been uncompressed?) and "add field" from the Arc Catalog data management toolset works. Still cannot add field from attribute table but I have not attempted using the "compact" tool as of yet.
Thanks to everyone
Retrieving data ...