We are having trouble deleting a version made in our 9.3.1 sde. When we attempt to delete it, ArcCatalog returns a message saying Unable to Delete - Target State not found in States table. Upon looking at the states table there is no reference to that particular version.

Is there any other way to delete this version? We will be upgrading to Version 10.1 soon, will this cause a problem or can it be deleted during the migration process?

  • sounds like a permissions issue - login as dba/admin - what database is arcsde using? oracle?
    – Mapperz
    Oct 1 '12 at 19:09
  • It's a sql database. I believe our admin did log in as dba but will double check w/him. Thanks!
    – Elizabeth
    Oct 1 '12 at 19:12
  • have you applied any arcsde service packs?
    – Mapperz
    Oct 1 '12 at 19:20
  • Yes, we have applied service packs. I believe this issue started when a version was created but somehow did not get processed correctly. The version can't be used, it appears corrupt, but we can't delete it.
    – Elizabeth
    Oct 1 '12 at 19:50
  • 1
    try stopping the sde service before deleting [sdeservice -o delete -i esri_sde] to stop the service try deleting.
    – Mapperz
    Oct 1 '12 at 20:17

There is an easy, unsupported way to do this in version 9.3.1 and below (I am not sure about 10, since I have not had to deal with that yet).

Just go ahead and delete the row in the "Versions" ArcSDE System table that has the version name you are trying to delete. Yes, this is not supported but it will work just fine. In case you are wondering why it would work, refer to this other question. Also, please make sure that it doesn't have any children versions or you will run into problems.

  • Interesting idea! None of the other suggestions has worked so far. This suggestion sounds pretty scary, though, deleting it straight from the table like that? Will spend time reading your links & then pass this along to our network guys. Thanks!
    – Elizabeth
    Oct 4 '12 at 18:50
  • The entry in the VERSIONS table is just a label that guarantees that the stateid will stay alive after a compress. Removing it means you are OK with it being candidate for pruning. It should work just fine. Oct 5 '12 at 1:01
  • FYI doing this on ArcSDE 10.X WILL break your geodatabase - by making it unavailable to open. It renders an error that notes that the version you deleted cannot be found if you attempt to connect to the geodatabase. I was able to fix this by doing an update query to re-add the row to the VERSIONS table.
    – Conor
    Jan 22 '14 at 18:51
  • Makes sense. GDB 10.x and higher use a radically different GDB schema... Jan 22 '14 at 23:14

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.