Can't delete an object
Comments
-
Hi...
this is my code, used for delete
I hope you serve...
public void DeleteFile(string documentumId)
{
try
{
DeleteProfile deleteProfile = new DeleteProfile();deleteProfile.IsDeepDeleteFolders = true;
deleteProfile.IsDeepDeleteChildrenInFolders = true;
deleteProfile.VersionStrategy = DeleteVersionStrategy.ALL_VERSIONS;OperationOptions operationOptions = new OperationOptions();
operationOptions.DeleteProfile = deleteProfile;ObjectIdentity sampleCabinetIdentity = new ObjectIdentity(new ObjectId(documentumId), _repository);
ObjectIdentitySet objIdSet = new ObjectIdentitySet();objIdSet.AddIdentity(sampleCabinetIdentity);
objectService.Delete(objIdSet, operationOptions);
}
catch (Exception ex) { throw ex; }
}0 -
error says its part of an assembly - I have to look up that syntax because I don't have it right at hand but if it just has a relation tied to it - like a WebPublisher template - the following will find it
select r_object_id from dm_relation where parent_id = '<object id of the object you want to delete'>'
select r_object_id from dm_relation where child_id = '<object id of the object you want to delete'>'
delete the relation first - then the object
0 -
Hello,
Also check if the document is part of a virtual document.
Regards.
0 -
Yep!
Running this query will give you all VM that contains the document you are trying to delete:
select * from dm_sysobject where r_object_id in (select parent_id from dmr_containment where component_id = 'Object ID of the document you try to delete')
Enjoy!
Al
0
Categories
- All Categories
- 107 Developer Announcements
- 53 Articles
- 104 General Questions
- 141 IM Services
- 43 OpenText Hackathon
- 32 Developer Tools
- 20.6K Analytics
- 4.1K AppWorks
- 8.9K Extended ECM
- 898 Cloud Fax and Notifications
- 76 Digital Asset Management
- 9.3K Documentum
- 29 eDOCS
- 118 Exstream
- 39.8K TeamSite
- 1.7K Web Experience Management