cancel
Showing results for 
Search instead for 
Did you mean: 

Unity API Updating Document Date

Soumya_Metta
Champ in-the-making
Champ in-the-making

How do we update the Document Date using Unity API to a new Date. Please provide with examples if you have any.

8 REPLIES 8

Aki_Daiguji
Star Contributor
Star Contributor

There are 2 ways to update the Document Date via the Unity API:

1. When first importing the document, you can provide the Document Date by providing the date value to the StoreNewDocumentProperties object.

2. For updaing the Document Date on an existing document, you will need to reindex the document via the Storage Class, using ReindexProperties object.

In both of these cases, the Properties object have a DocumentDate property that you can set the date value to.

 

Soumya_Metta
Champ in-the-making
Champ in-the-making

Thanks, for the response. According to the SDK you cannot re index a document if Document Type doesn't change. Is that apply in the scenario where we want to change only the document date?

Aki_Daiguji
Star Contributor
Star Contributor

I apologize, there is another way to modify the Document Date; Off of the Document object, you can create a DocumentPropertiesModifier object, which from this, you can change the Document Date without changing anything else about the document.

 

Soumya_Metta
Champ in-the-making
Champ in-the-making

Thanks, Aki for the response. We were trying to use that for Retention Project. It appears to not be working.

Here is the problem:

We have over a million documents that were converted into OnBase and the Document Date was set as the load date instead of the original age of the document. We set a dynamic retention period on those documents to use the document date and are trying to modify the document date with the original date.

We learned that the dateexpire column from the hsi.docretdynamic table is only set at the time document is loaded or reindexed. If we reindex thru workflow the action opens up the reindex UI for each document whcih doesn't work for the number of documents we need to change. So we were going to try the API and the API states that we cannot reindex to the same document type and using the DocumentPropertiesModifier object that you suggested is not updating the dateexpire column in the table hsi.docretdynamic.

So the question is how can we modify the dateexpire for over a million documents for our dynamic retention on document types?

 

Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.