Export-mailbox and Exact match
2007 Sp3 w/RU1 I am trying to use Export-mailbox to grab an exact match of a phrase like what Exmerge can do. I use –contentkeywords, but it grabs a substring of the phrase. This is a big problem because I want to –deletecontent, but of course won’t do it until I confirm it is only grabbing my exact phrase match.
January 19th, 2011 2:25pm

Hi, The example shows how to use filters to specify which items in the source mailbox to include in the export. This example exports all items from the mailbox of user contoso\john that have the keyword "merger" in the message body or in the content of an attachment, have an attachment that is named *orgchart*. Export-Mailbox -Identity contoso\john -TargetMailbox ExportMailbox -TargetFolder MyData -ContentKeywords "merger" -AttachmentFilenames "*orgchart*" Please remember to click Mark as Answer on the post that helps you, and to click Unmark as Answer if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Thanks Gen Lin-MSFT
Free Windows Admin Tool Kit Click here and download it now
January 24th, 2011 4:16am

Gen, thanks for your reply. You example works for a single word, however if I want to grab email that has "merger process" and not "merger finished", if I use "merger process" for the ContentKeywords value, it will grab both "merger process" and "merger finished". This makes export-mailbox pretty much unusable when you want to -DeleteContent because if will delete more than what is expected.
January 24th, 2011 11:57am

I have witnessed the exact same problematic behavior with Export-Mailbox. I have a legitimate discovery search to perform that includes the keyword "testing", but the actually result will also export anything that partially matches like "test". Export-Mailbox "Alias" -TargetMailbox Export -TargetFolder '1' -ExcludeFolders "\Calendar","\Contacts","\Journal","\News Feed","\Notes","\RSS Feeds","\Suggested Contacts","\Sync Issues","\Sync Issues1","\Tasks" -SubjectKeywords "Testing" -StartDate "06/01/2009" -EndDate "02/28/2011" The result of the cmdlet above with export messages where the subject includes only “test” which produces too many bad entries. Does Microsoft have a fix for this bug? Exchange version 8.1 (Build 240.6)
Free Windows Admin Tool Kit Click here and download it now
December 8th, 2011 4:10pm

Include me in on this question. The documentation for export-mailbox uses Legal Discovery as an applicable use for the cmdlet. Legal discovery searches sometimes lead to Exchange Admins on "the stand" in a court of law. We need to be able to say that we have searched for and produces the required criteria, exactly not almost.
June 22nd, 2012 9:11am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics