0

I understood that metadata/property sync is bi-directional in the SharePoint library.

  • Suppose title metadata is updated in the SharePoint Online library for a document. In that case, it automatically syncs with the title property of the Word document, and the title property in the word document gets updated.
  • If a document is uploaded to the SharePoint library manually and if that document contains title property, then it will overwrite the title metadata of the document in the SharePoint library

Also, I have observed that bi-directional sync is not happening in a few libraries. What could be the possible reason, the sync is disabled in a few libraries in SharePoint Online?

  • When updating the SharePoint title metadata, then the word property - title is not getting sync with it
  • When uploading a document (which has Title property) in these libraries, it does not override the document Title metadata in SharePoint.

I want to understand if we update only a few metadata (for example Status) in SharePoint for a word document where the content type has these columns - (Title, Description, Approver, Reviewer, Process, Number, Functions, Status), and if a word file has few similar columns (Title, Functions, Status) in the property, how Sync will behave?

1 Answer 1

1

Default / OOTB behavior of SharePoint Document’s Metadata Sync / Document Parser

  • Sync is enabled by default in every SharePoint library. Document metadata sync is bi-directional (SharePoint Online to MS Office Files and MS Office Files to SharePoint Online). Sync only occurs when metadata is updated on SharePoint Online or content of document or property is updated in MS Office Files (Word, Excel, PPT, etc).
  • If the SharePoint Online library has a content type, as soon as any metadata is updated in SharePoint Online, all columns of content type will be synced in Word / Excel / PowerPoint documents property, we can see all columns in Word / Excel / PowerPoint properties with values.
  • If any metadata is updated in the SharePoint library for a document, it automatically syncs with Word / Excel / PowerPoint document’s property and Word / Excel / PowerPoint properties get updated.
  • If a Word / Excel / PowerPoint document is opened directly from SharePoint Online library and its title or any property is updated, then it overwrites the title or metadata of the document in SharePoint library; ideally no one does this, users edit metadata from SharePoint Online and not from Word / Excel / PowerPoint property.
  • If a document is uploaded to the SharePoint library manually and if that document contains any property which matches the name of SharePoint library metadata, then it will overwrite that metadata of the document in the SharePoint library

Pros and Cons of disabling Sync or Document Parser

Pros:

  • MS Office Files (Word, Excel, PPT, etc) property updates will never impact SharePoint Online metadata
  • Any document the user uploads will not result in overwriting of metadata in SharePoint Online, regardless
  • User will not have to clear property before upload
  • If a user manually updates any metadata in the SharePoint Online library, the remaining metadata will never sync from MS Office Files (Word, Excel, PPT, etc) to SharePoint Online

Cons:

  • If sync is disabled in a library, SharePoint Online metadata changes will not reflect in MS Office Files (Word, Excel, PPT, etc) property.
  • If in the future Microsoft releases any feature related to sync or MS Office Files (Word, Excel, PPT, etc) property, that will not be usable and you have to contact Microsoft to use that.
  • Or, if in the future you want to write any functionality to read a property from MS Office Files (Word, Excel, PPT, etc) to create any report or feature, that will not be possible. You will have to depend on SharePoint Online to read the metadata

If you disable Sync as of today and enable it in future

  • Since Document Parse is enabled by default in all SharePoint Online libraries that means as of today, sync will have been completed for all documents that are added or updated in your tenant in all SharePoint Online libraries. This means all columns of SharePoint Online are available in MS Office Files (Word, Excel, PPT, etc) property for these documents.
  • In the future, if sync will be enabled then for all documents updated (between date of disabling and reenabling) ALL metadata will have to be resaved in SharePoint Online using PS script or Power Automate so that all columns values sync from SharePoint Online to MS Office Files (Word, Excel, PPT, etc)
  • If a user updates the document and its property manually, and not using Edit All option from SharePoint Online, then the sync will be MS Office Files (Word, Excel, PPT, etc) to SharePoint Online.
  • User must be given Edit access only after the above activity is completed, otherwise, there could be a possibility of MS Office Files (Word, Excel, PPT, etc) to SharePoint Online sync if any document gets updated mid-way

Pseudocode to disable or enable Sync or Document Parser

Document metadata sync is bi-directional (SharePoint Online to MS Office Files and MS Office Files to SharePoint Online):

To Disable Sync or Document Parser use this –

$list = $ctx.Web.Lists.GetByTitle($ListName)

$ctx.Load($list)
$ctx.ExecuteQuery()

$list.ParserDisabled = $true
$list.Update()
$ctx.ExecuteQuery()

Write-Host "Disabled"

To Enable Sync or Document Parser use this –

$list = $ctx.Web.Lists.GetByTitle($ListName)

$ctx.Load($list)
$ctx.ExecuteQuery()

$list.ParserDisabled = $false
$list.Update()
$ctx.ExecuteQuery()

Write-Host "Enabled"

Recommendation / Best Practice

  • I’d recommend that sync must be enabled (i.e document parser must be enabled) in each library as this is SPO’s default behavior.
  • If there is any specific need as per your design, then you can disable it but make sure you validate all Cons before taking any decision.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.