I have an O365 platform, and in one of the site collections I have a document library with files that are uploaded using a standard naming convention: <Business Unit>_<ITIL Practice>_<Document Type>_<Document Description>. Examples below:
ITSM_KM_POLICY_KnowledgeManagementPolicy.docx
ITSM_CM_PROCESS_ChangeManagementProcessTemplate.pdf
ITSM_AM_PROCESS_ManagingOrganizationalAssets.pdf
ITSM_KM_GOV_KnowledgeManagementGovernanceFramework.pdf
The library has 3 managed metadata columns:
1) Business Unit
2) ITIL Process
3) Document Type
I also have a managed term store, with the following hierarchy:
Branch 1
Parent term 1: Business Unit
Child terms 1: ITSM, ITSB, ITSA
Branch 2
Parent term 2: ITIL Practice
Child terms 2: KM, CM, AM, EM
Branch 3
Parent term 3: Document Type
Child terms 3: Policy, Process, Gov, Training
I would like to set up a flow that runs whenever a file is added or modified in the library, and which compares each part of the filename with the relevant term store branch, and where it finds a match, to apply the matched term store value in the correct metadata column. Where it doesn't find a match, it leaves the value blank.
Any help would really be appreciated. Let me know if you need more information.