Avatar of Kelly Garcia
Kelly Garcia
Flag for United Kingdom of Great Britain and Northern Ireland asked on

Select SamAccountName - powershell script

Hi All,

I have written the code below and it will not display the SamAccountName, please help!

get-mailbox -ResultSize Unlimited | Get-MailboxStatistics | where {$_.TotalItemSize -ge "4GB"} | Select-Object @{Name="DisplayName1";Expression={Get-Mailbox $_ | select -ExpandProperty SamAccountName}}, TotalItemSize, ItemCount, Database, TotalDeletedItemSize,DeletedItemCount, LastLoggedOnUserAccount, LastLogonTime, LastLogoffTime

Open in new window

PowershellScripting Languages

Avatar of undefined
Last Comment
Kelly Garcia

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Kelly Garcia

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Kelly Garcia

ASKER
this works
Your help has saved me hundreds of hours of internet surfing.
fblack61