Change non-document object to document?

We have a vault where there is one object and class with attached documents. It was not set up as a class of the Document object type.

The annoyance of not using the document object is the extra clicks one needs to do to view an attached document vs with a document class the document sort of is the object and clicking on the object previews the document.

So we would like to change these objects to documents. In fact over 200000 of them.

It appears you can programmatically change an object from one class to another but you can't change the object type (eg change to object type Document)

Any ideas how this change could be made? would each existing object's properties need to be read and then a new object created using the read property data?

Parents
  • Hi Chris,

    Each object type has its own set of unique internal IDs for its objects. If you were allowed to change the object type it is very likely that those IDs will not be unique in the new object type. There are probably more technical obstacles but this alone is enough to conclude that you need to create all of those objects as new document objects with new IDs. That is a major task with 200.000 objects including files.

    One possible path would be to export the objects and their files and then import them again. However, with this number of objects I would look for a more internalized approach using a VAF or a script or perhaps even one of the existing add ons that might be able to create new objects while copying your files and metadata. I would expect that the latter is possible. The tricky part might be how to trigger the process. Hope someone can point out a suitable solution for you.

    BR, Karl

Reply
  • Hi Chris,

    Each object type has its own set of unique internal IDs for its objects. If you were allowed to change the object type it is very likely that those IDs will not be unique in the new object type. There are probably more technical obstacles but this alone is enough to conclude that you need to create all of those objects as new document objects with new IDs. That is a major task with 200.000 objects including files.

    One possible path would be to export the objects and their files and then import them again. However, with this number of objects I would look for a more internalized approach using a VAF or a script or perhaps even one of the existing add ons that might be able to create new objects while copying your files and metadata. I would expect that the latter is possible. The tricky part might be how to trigger the process. Hope someone can point out a suitable solution for you.

    BR, Karl

Children
No Data