Quantcast
Channel: Exchange Server 2010 Forum
Viewing all articles
Browse latest Browse all 3147

get-mailboxstatistics not showing Totalitemsize when specifying e.g Value.ToKB

$
0
0

I want to use the Totalitemsize as an iteger for charts So I need to convert the xxxxxB to xxxxx (does not matter if it is in bytes, Kb, MB,.. as long as it is a number)

What does work but then it is not a number:

Get-MailboxStatistics -database 'ETRO2' | ft DisplayName,TotalItemSize,ItemCount

What does not work (result is just a blank in the formatte list):

Get-MailboxStatistics -database 'ETRO2' | Format-Table DisplayName,DatabaseName, TotalItemSize.value.ToMB

or

Get-MailboxStatistics -database 'ETRO2' | ft DisplayName,@{ expression={$_.TotalItemSize.Value.ToKB()}},ItemCount

or

Get-MailboxStatistics -database 'ETRO2' | ForEach { New-Object psobject | Add-Member -Passthru NoteProperty Displayname $_.Displayname | Add-Member -Passthru NoteProperty TotalItemSize $_.TotalItemSize.Value.ToKB() }

 


Viewing all articles
Browse latest Browse all 3147

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>