Link to home
Start Free TrialLog in
Avatar of Mike Satterfield
Mike Satterfield

asked on

Exchange 2010 search-mailbox query syntax

I am trying to use the following EMC command:

Search-Mailbox -Identity "<user>" -SearchQuery 'Subject:"Example subject"' -DeleteContent

And it works, the problem is, almost too well. So it will go into a mailbox and delete any email with the subject:

Example Subject

but it will also delete any with the subject

RE: Example Subject
FW: Example subject

etc..

my question is how do I do this, and have the exact string, so it won't delete variations of it ?

Thanks,
Avatar of Mahesh
Mahesh
Flag of India image

Avatar of Mike Satterfield
Mike Satterfield

ASKER

That is basically running the same command that I am. Mine does work. I just want to delete the original email only. not any "RE:" or "FW:"

my problem is that it deletes, any responses, or forwards as well.
ASKER CERTIFIED SOLUTION
Avatar of SubSun
SubSun
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial