→ 🚀Are you a Lansweeper Champion?! Join our Contributor Program Sign up here!

Community FAQ
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
nhouse24
Engaged Sweeper II
I am looking for a report that will detail Exchange mailbox usage but also allow it to filter out mailboxes over or under a specific size.
1 REPLY 1
nhouse24
Engaged Sweeper II
I found my own solution. This code will filter out mailbox sizes over just under 1 GB.

SELECT TOP (1000000) tblExchangeMailbox.DisplayName, tblExchangeMailbox.Alias, tblExchangeMailbox.RecipientTypeDetails, addresses.email AS EmailAddress, tblExchangeServer.AssetId AS ServerAssetId,
tblExchangeServer.Name AS ExchangeServer, tblExchangeMailboxStatistics.TotalItemSize
FROM tblExchangeMailbox LEFT OUTER JOIN
(SELECT MIN(Address) AS email, MailboxId
FROM tblExchangeMailboxAddress
GROUP BY MailboxId) AS addresses ON addresses.MailboxId = tblExchangeMailbox.MailboxId INNER JOIN
tblExchangeServer ON tblExchangeServer.ServerId = tblExchangeMailbox.ServerId INNER JOIN
tblExchangeMailboxStatistics ON tblExchangeMailbox.MailboxId = tblExchangeMailboxStatistics.MailboxId
WHERE (tblExchangeMailboxStatistics.TotalBytes > 900000000)
ORDER BY tblExchangeMailboxStatistics.TotalBytes DESC

Reports & Analytics

Ask about reports you're interested in and share reports you've created. Subscribe to receive daily updates of reports shared in the Community.

New to Lansweeper?

Try Lansweeper For Free

Experience Lansweeper with your own data.
Sign up now for a 14-day free trial.

Try Now