Script functions reference > Script functions in alphabetical order > P > PPCommitDocMDUpdate

PPCommitDocMDUpdate
Syntax
PPCommitDocMDUpdate();
Description
This script function is used together with PPBeginDocMDUpdate, and is called after a SaveCurrMetadata, SaveSegMetadata or SavePPMetadata script function. It is used to store the cached metadata in the Document Broker repository.
PPCommitDocMDUpdate can be used at any post-processing script level. For example, if PPBeginDocMDUpdate is called at Job Begin and PPCommitDocMDUpdate is called at Job End, all metadata belonging to all documents are saved when the post-processor job finishes.
Example
PPBeginDocMDUpdate();
$doc_id = GetFirstSegDoc();
while(num($doc_id) > 0)
{
   $ret = SetSegMetadata($doc_id, "city", "Prague");
   $ret = SaveSegMetadata($doc_id, "city");
   $doc_id = GetNextSegDoc($doc_id);
}
PPCommitDocMDUpdate();
OpenText StreamServe 5.6 Updated: 2013-03-01