문제

So apparently managed metadata fields are not supported with ODATA Filter Queries in MS Flow. We need a workaround so we can filter the results from a 'Get items' action. Does anyone know a clever way (besides copying the metadata to a text field) to filter on managed metadata using Flow?

도움이 되었습니까?

해결책

If you have a list named Test that contains a managed metadata field named Department, you can get all of the items where the value of the Department field is Accounting using the following SharePoint REST API POST request:

_api/Web/lists/getByTitle('Test')/GetItems(query=@v1)?@v1={"ViewXml":"<View><Query><Where><Eq><FieldRef Name='Department'/><Value Type='TaxonomyFieldType'>Accounting</Value></Eq></Where></Query></View>"}

In Flow you would use the Send an HTTP request to SharePoint to make that REST API call.

SharePoint REST API call in Flow

You could then use a Select action to extract the values you need from the response. In the example below I'm selecting the value of the Title field.

Using the Select action to extract the Title field values

The value of the From expression is: body('Send_an_HTTP_request_to_SharePoint')['d']['results']

The value of the Title expression is: item()['Title']

다른 팁

There is a workaround for this issue is adding a Condition. Then use the dynamic content of Managed metadata label to check if it equal to the specific value.

More information check the similar post:

https://powerusers.microsoft.com/t5/Building-Flows/Filtering-taxonomy/td-p/278941

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top