FREE STUDY NOTES · SC-401

Building eDiscovery searches with the condition builder and KeyQL

How to build Microsoft Purview eDiscovery searches with the condition builder and KeyQL, with example queries and the search limits to know.

From Ultra Transcenders SC-401 by Tony Rough (coming December 2026)

Searches are built on a case’s Searches tab by choosing data sources and then a query, using either the condition builder or the Keyword Query Language (KeyQL) editor.

Condition builder

Condition group Examples
Common (mailboxes and sites) Date, Sender/Author, Size (in bytes), Subject/Title, Retention label; premium: Content kind, Content source application, Identifier
Mail Message kind, Participants (From, To, Cc, Bcc), Recipients (To, Cc, Bcc), Sender, To, Received, Sent, Subject, Item class; premium: Topic
Documents Author, Created, File type, Last modified, Title; premium: Path, Sensitive information type, Sensitivity label

The Date condition offers Before, After and Between; the Size condition adds Greater, Less, Equals and similar numeric operators. For imported mail, Received and Sent are more reliable than Date.

KeyQL rules

(subject:"project falcon" OR budget*) AND kind:email AND received>=2026-01-01
participants:user1@example.com AND sent=2026-03-01..2026-03-31
kind:microsoftteams AND "release date"
path:"https://example.sharepoint.com/sites/Finance/" AND filetype:xlsx

The first line finds email whose subject contains the phrase or any term starting with “budget” received on or after 1 January 2026; the second finds mail involving one user in March; the third finds Teams chats, meetings and calls containing a phrase; the fourth limits results to Excel files in one site.

Search limit Standard Premium
Characters in a query (including permission filters) 10,000 10,000
Boolean operators in a query 100 100
Sensitive information types per query 20 20
Participants per query 25 50
Keyword segments, targeted search 20 100
Keyword segments, tenant-wide search 5 5
Recommended locations in a targeted search 1,000 1,000
Locations in a tenant-wide search 500,000 500,000

Microsoft Security Copilot can draft KeyQL from natural language (preview), but the result still has to be pasted into the KeyQL condition and run.

Common trap: Writing *report or rep*rt to catch variants - eDiscovery supports only prefix wildcards such as report*, and only with at least three characters before the asterisk.

Common trap: Typing to: user1@example.com with a space after the colon - the space turns the value into a full-text keyword search instead of a recipient filter.

Get the whole book

This note is one section of Ultra Transcenders SC-401: Administering Information Security in Microsoft 365, an independent study guide that explains every topic the exam covers by technology, with comparison tables, diagrams and the common traps, plus a glossary linked to Microsoft Learn.

Amazon.co.ukKindle: coming soonPaperback: coming soon
Amazon.comKindle: coming soonPaperback: coming soon

Due on Amazon in December 2026, in Kindle and paperback editions.

About the book · SC-401 terms in the glossary · All SC-401 study notes

More SC-401 study notes