Microsoft Graph - Filter Messages by Categories

Paulus Dettmer 25 Reputation points
2023-11-07T08:26:55.1933333+00:00

Hello,

after searching for how to filter messages by categories with the MS Graph I stumbled upon this thread already answering half of my question:

$filter=categories/any(a:a eq 'Orange Category') OR categories/any(b:b eq 'Red Category')

finds all messages that contain either red or orange (or both) category.

Now I want to filter for all messages containing the red AND the orange category. But while the upper query returns all expected results, the query with AND

$filter=categories/any(a:a eq 'Orange Category') AND categories/any(b:b eq 'Red Category')

does not yield any results, even tho the upper query returns results that have both, orange and red, category.

Is there something i can do about that?

Thank you very much in advance

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
10,914 questions
0 comments No comments
{count} vote

0 additional answers

Sort by: Most helpful