Forum Discussion

thorrr7's avatar
thorrr7
Copper Contributor
Nov 30, 2021
Solved

Exchange 2016 ComplianceSearch not work

hi everyone,
 

I want to soft delete all email contents in multi mailboxes in bulk.  New-ComplianceSearchAction cmdlet seems could achieve it, but it just could delete 10 messages one time..

i tested cmdlets below, but return results are zero.

 

 

New-ComplianceSearch -Name "test" -ExchangeLocation "<user id>" | Start-ComplianceSearch

Get-ComplianceSearch | FL name,items,size,jobprogress,status

New-ComplianceSearchAction -SearchName "test" -Purge -PurgeType SoftDelete

 

 

 Can you help me why search result is blank?

  • If you have single-item recovery enabled, they won't be permanently deleted. Same if the mailbox is on hold. And you can always use the other switched to make a copy of the deleted content. Bets having to run the same thing 100x times, at least in my book 🙂

    As to why you're not getting any results, I'm not sure. Try adding some generic query instead, although it *should* include the whole content of the mailbox when no keywords are provided...
    • thorrr7's avatar
      thorrr7
      Copper Contributor

      VasilMichev  hi Vasil, because i dont want to hard delete message, in case someone needs  recover messages..

      • If you have single-item recovery enabled, they won't be permanently deleted. Same if the mailbox is on hold. And you can always use the other switched to make a copy of the deleted content. Bets having to run the same thing 100x times, at least in my book 🙂

        As to why you're not getting any results, I'm not sure. Try adding some generic query instead, although it *should* include the whole content of the mailbox when no keywords are provided...

Resources