Solved

Exchange PowerShell Command to find blank values

Posted on 2010-09-02
4
921 Views
Last Modified: 2012-05-10
How can I filter the results of an Exchange 2007 command shell command for values that have a blank value?  I know how to do it for a certain value.  For example:

get-mailbox | where {$_.ManagedFolderMailboxPolicy -eq "30 Day Deleted Item Retention Policy"}

How do I filter for mailboxes where $_.ManagedFolderMailboxPolicy is blank?
0
Comment
Question by:SRSVegas
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 5

Accepted Solution

by:
duraswitch earned 500 total points
ID: 33592723
try:
get-mailbox | where {$_.ManagedFolderMailboxPolicy -eq $Null}
0
 
LVL 32

Expert Comment

by:endital1097
ID: 33593240
sometimes the -eq $null doesn't work
in those instance you can try the following
Get-Mailbox | where {!$_.ManagedFolderMailboxPolicy}
0
 
LVL 32

Expert Comment

by:endital1097
ID: 33596395
have you had a chance to try out these solutions?
0
 

Author Closing Comment

by:SRSVegas
ID: 33600030
get-mailbox | where {$_.ManagedFolderMailboxPolicy -eq $Null} worked.  Without -eq $Null I get every mailbox back.

Thanks,
ML
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to install and use the NTBackup utility that comes with Windows Server.
Auditing domain password hashes is a commonly overlooked but critical requirement to ensuring secure passwords practices are followed. Methods exist to extract hashes directly for a live domain however this article describes a process to extract u…
In this video we show how to create an email address policy in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.:  First we need to log into the Exchange Admin Center. Navigate to the Mail Flow…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question