Solved

Exchange 2010 Get-Message powershell

Posted on 2013-12-03
5
2,460 Views
Last Modified: 2013-12-04
Exchange 2010 Get-Message powershell

I need to query exchange queue for the messages that have the date expired but are still in the queue.
I used the powershell below, but it retrieves the date Received, I am looking for the display of the expiration date of the message.

Get-Message -IncludeRecipientInfo -Filter {Status -eq "Retry"} | Format-Table FromAddress,Recipients,Subject,Da
teReceived

Thank you
0
Comment
Question by:jskfan
  • 3
  • 2
5 Comments
 
LVL 37

Assisted Solution

by:Jamie McKillop
Jamie McKillop earned 500 total points
ID: 39693763
Hello,

You want the ExpirationTime

Get-Message -IncludeRecipientInfo -Filter {Status -eq "Retry"} | Format-Table FromAddress,Recipients,Subject,DateReceived,ExpirationTime

-JJ
0
 

Author Comment

by:jskfan
ID: 39693870
it works...Thanks.
I wonder if there is a way to display the content of the fields without being truncated ?
0
 

Author Comment

by:jskfan
ID: 39693876
it is showing this way:

  Subject
  -------
. Undeliverable: You'r...
. Undeliverable: Répon...
. Undeliverable: Répon...
. Undeliverable: Follo...
. Undeliverable: Follo...
. Undeliverable: Répon...
. Undeliverable: Eonom...
. Undeliverable: Répon...
. Undeliverable: Répon...
. Undeliverable: Répon...
. Undeliverable: Répon...
. Undeliverable: Répon...
0
 
LVL 37

Accepted Solution

by:
Jamie McKillop earned 500 total points
ID: 39695384
Not in a table format. You could display it in list format:

Get-Message -IncludeRecipientInfo -Filter {Status -eq "Retry"} | select FromAddress,Recipients,Subject,DateReceived,ExpirationTime

-JJ
0
 

Author Closing Comment

by:jskfan
ID: 39696069
Excellent!!

Thank you
0

Featured Post

Is Your AD Toolbox Looking More Like a Toybox?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

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

Exchange server is not supported in any cloud-hosted platform (other than Azure with Azure Premium Storage).
Scam emails are a huge burden for many businesses. Spotting one is not always easy. Follow our tips to identify if an email you receive is a scam.
To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
how to add IIS SMTP to handle application/Scanner relays into office 365.

810 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