Forum Discussion
Joshua Gordon
Sep 22, 2018Copper Contributor
SharePoint Online - Can metadata be applied recursively when uploading a folder?
Hi All,
My organization is going to be rolling out SharePoint online in the coming months and looking over the new document libraries, it looks like there are some really nice features. One thing I wanted to ask about is whether it's possible to apply metadata recursively after I upload a folder full of subfolders and files.
The scenario here is that I have a team member working on a project. All project files are stored in a folder with multiple subfolders and multiple files within each subfolder. When the project is completed and we want to store this within a SP doc library, I'd like to ensure that all files from this project are tagged with certain metadata. I know if I drag the folder into the SP doc library, I can apply metadata to the parent folder but is there a way to have this metadata trickle down recursively so that ALL the files and subfolders also get these metadata fields?
My assumption here is that there would have to be some kind of script written to achieve this but if there's a native way to apply metadata (something like a check box for "apply to all files and subfolders" or similar), I'd love to know about it.
Thanks in advance for any tips!
2 Replies
Sort By
- SderixCopper Contributor
The answer Juan gave is correct.
As I understand things you are in the process of roling out SharePoint within your organization.
At current you are hosting projects on fileservers and while you are provisioning (creating (project)sites) SharePoint the need arises to migrate the files/folders from a specific project to a specific SharePoint (project) site (collection).
What you need to take into account is that - in SPO - you can only drag folders with files into a modern document library, not a classic document library.
What you could do, as a workaround, is setup migration tooling (like ShareGate - and no I am in no affiliated to them other then I really like the product).
You then have several options:
1-'manually' configure ShareGate to migrate a part of the file share to a specific site including metadata
2-use scripting to setup a (semi) automated process.
HTH!
- Besides the bulk metadata update that could help here, there is not a native way to achieve the scenario you have just described so you will have to automate it:
(1) A Flow could be an option, but since it seems you will have a complex folder structure it might not be easy to build that Flow
(2) A Script / Piece of code that uses SPO API (CSOM) should do what you need