This script prints out each database and gives a count of how many users on each database

###
clear-host
write-host -fore yellow “This script will get each mailboxdatabase and the current user count “
foreach($name in get-mailboxdatabase)
{
write-output “$name”
$count=(get-mailbox -database $name).count
if($count -eq $null)
{ write-host -fore red “Empty Database, no users”
}
else
{ write-output $count }
}
write-host -fore yellow “The system has a total of “$user=(get-mailbox – resultsize:unlimited).count
write-host -fore red $user

broken fences movie goofs watchmen captain america movie stargate continuum movie rumor superhero movie australia the movie batman gotham knight wanted movie good dick movie actors kill me later kids movie monster the movie credits its pat movie synopsis sweeney todd the demon barber of fleet street next movie