9 Replies Latest reply on Jun 20, 2013 7:14 AM by Lucas W.

    DELETE_DOC and remaining records in table REVCLASSES

    Lucas W.

      Hello WebCenter Content masters,

      I am facing a strange and troublesome issue.

      I have several documents with dDocName I manage (not automatically generated). I deleted a bunch of them (about 100) using RIDC service DELETE_DOC. But when I try to check-in new documents with the dDocName of those deleted items, I got an error :

      intradoc.common.ServiceException: !csServiceDataException,CHECKIN_NEW_SUB,makeNewRevClass!$ *ScriptStack CHECKIN_NEW_SUB

      3:doScriptableAction,dDocName=638470463:doSubService, dDocName=63847046CHECKIN_NEW_SUB, dDocName=638470463:makeNewRevClass, dDocName=63847046


      Caused by: intradoc.data.DataException: !csDbUnableToExecuteQuery, IrevClasses(INSERT INTO RevClasses (dRevClassID\, dDocName\, dDocCreator\, dDocCreatedDate\, dDocLastModifier\, dDocLastModifiedDate\, dDocOwner\, dDocFunction) VALUES(2894314\, '63847046'\, 'admin'\, {ts '2013-06-11 09:15:59.745'}\, 'admin'\, {ts '2013-06-11 09:15:59.745'}\, 'admin'\, ''))!$ORA-00001: unique constraint (PRD_OCS.DDOCNAME_REVCLASSES) violated


      Caused by: java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (PRD_OCS.DDOCNAME_REVCLASSES) violated


      So I checked the REVCLASSES table and was surprised to see there was still records of deleted documents.


      select * from documenthistory where ddocname='63847046' order by dactiondate desc;

      24/05/13 14:13:00,000000000 121467985 2172024 2172070 admin 63847046 Delete Document Public

      24/05/13 14:13:00,000000000 121468000 2172024 2172070 admin 63847046 Delete Revision Public

      15/05/13 02:04:00,000000000 121481564 2172024 2172070 admin 63847046 Checkin Public


      select * from revisions where ddocname='63847046';



      select * from revclasses where ddocname='63847046';

      2172070 63847046 2172024 15/05/13 02:04:41,455000000 system 15/05/13 02:04:41,000000000 admin admin (null)


      I cannot figure out what happened, and cannot reproduce the issue. Normally, documents I delete with DELETE_DOC no more exist in REVCLASSES table.

      I tried to run a Collection Rebuild Cycle, thinking it would clean the database, but in vain.


      So, my question is : is there a way to perform a kind of clean-up of the database, which would remove this kind of error? or should I remove those "ghost" records manually?


      Thank you for reading.