Solved

Get-Mailbox with users database and jobtitle

Posted on 2013-12-10
6
1,844 Views
Last Modified: 2013-12-10
Wondering if anyone can help out with this, I'm looking to find all the mailboxes with users database and what their job title is.

I have run this EMC cmdlet though not quite getting what im looking for.

Get-Mailbox -ResultSize Unlimited | select firstname, lastname, primarysmtpaddress, jobtitle, database | Export-Csv c:\SMTPList.csv

it gives me a list of all the mailboxes and what the Primary SMTP Address is and what database but not the jobtitle.

Exhchange 2007.

Thanks.
0
Comment
Question by:damejen
[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
  • 3
  • 3
6 Comments
 
LVL 40

Accepted Solution

by:
Subsun earned 500 total points
ID: 39708294
Get-Mailbox output does not have properties called jobtitle, firstname & lastname. You need to create custom properties to get these details in your report..
Try..
Get-Mailbox -ResultSize Unlimited | % {
$Obj = $_ | Get-Recipient
$_ | Select @{N="firstname";E={$Obj.firstname}}, @{N="lastname";E={$Obj.lastname}}, primarysmtpaddress,@{N="JobTitle";E={$Obj.Title}}, database
}| Export-Csv c:\SMTPList.csv

Open in new window

0
 

Author Closing Comment

by:damejen
ID: 39708310
Brilliant!!! Thanks for the help Subsun, this hit the nail on the head.
0
 

Author Comment

by:damejen
ID: 39708539
Hi Subsun, hope you could help with adding something else to this, getting the mailbox sizes as well? Not sure if you would pipe Get-MailboxStatistics in there somehere?

thanks.
0
Transaction Monitoring Vs. Real User Monitoring

Synthetic Transaction Monitoring Vs. Real User Monitoring: When To Use Each Approach? In this article, we will discuss two major monitoring approaches: Synthetic Transaction and Real User Monitoring.

 
LVL 40

Expert Comment

by:Subsun
ID: 39708663
Try this..
Get-Mailbox -ResultSize Unlimited | % {
$Obj = $_ | Get-Recipient
$_ | Select @{N="firstname";E={$Obj.firstname}}, @{N="lastname";E={$Obj.lastname}}, primarysmtpaddress,@{N="JobTitle";E={$Obj.Title}},database,@{N="TotalItemSize";E={($_ | Get-MailboxStatistics).TotalItemSize}}
}| Export-Csv c:\SMTPList.csv

Open in new window

In future please open a new question for additional requests.. :-)
0
 

Author Comment

by:damejen
ID: 39708720
Thanks a million Subsun. Works like a charm.
0
 
LVL 40

Expert Comment

by:Subsun
ID: 39708728
You are welcome!
0

Featured Post

Technology Partners: 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

INTRODUCTION The purpose of this document is to demonstrate the Installation and configuration of the Data Protection Manager product. Note that this demonstration was prepared on the basis of Windows OS is 2008 R2 and DPM 2010. DATA PROTECTI…
The new Microsoft OS looks great, is easier than ever to upgrade to, it is even free.  So what's the catch?  If you don't change the privacy settings, Microsoft will, in accordance with the (EULA) you clicked okay to without reading, collect all the…
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …

688 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