SOLVED

SharePoint Online document library - original metadata lost when replacing documents

Brass Contributor

Hello,

My issue is that when replacing/drag&droping the document with an exact name, the metadata that was originally there gets all wiped out, and I end up re-applying all of them. Also, the behavior is inconsistent. In some other document libraries, after replacing the document and losing the metadata values, I re-apply a value in one column, and then SPO auto-fills other fields to match the lost metadata values.

 

Does anyone have any ideas why it happens and how to fix it?

 

Thank you,

Rhea

2 Replies
best response confirmed by Rie0205 (Brass Contributor)
Solution
Hi @Rie0205 - I have a guess.

When you save an Office file in a SharePoint library that has custom metadata, that information is embedded within the document. You can see this by downloading a file (which has custom metadata in the columns for it), changing its name, and then uploading it back to that same library (or another library with the columns of the same name). The original metadata will appear in the library's columns.

SO, my guess is that you are uploading a file that was stored in a library with metadata columns with the same name as the library you're uploading the file to. These are embedded within your file as blank and those values then overwrite the metadata columns when you upload it.

@Rie0205 , we're having a similar issue where Excel files in libraries on unrelated sites, lose their metadata and in fact, lose all of our organization's managed metadata and custom metadata. We opened a case and the recommendation provided was to clear the Office cache and to select the option to delete cached files on close. That has fixed some other issues, but not this particular issue. These files do not inherit the metadata from the SPO site - I expect it may be because they are macro-enabled files which are protected, but I'm not sure. Unprotecting them doesn't enable them to inherit the metadata from the SPO site. 

1 best response

Accepted Solutions
best response confirmed by Rie0205 (Brass Contributor)
Solution
Hi @Rie0205 - I have a guess.

When you save an Office file in a SharePoint library that has custom metadata, that information is embedded within the document. You can see this by downloading a file (which has custom metadata in the columns for it), changing its name, and then uploading it back to that same library (or another library with the columns of the same name). The original metadata will appear in the library's columns.

SO, my guess is that you are uploading a file that was stored in a library with metadata columns with the same name as the library you're uploading the file to. These are embedded within your file as blank and those values then overwrite the metadata columns when you upload it.

View solution in original post