Is it possible to get a list of all mailboxes (email addresses) with data on the archive server?

Is it possible to get a list of all mailboxes (email addresses) with data on the archive server?

I just need to extract the list of mailboxes with their email addresses and size of data for them

  • You can run the following SQL script ...

    Use ArchiveManager
    select ma.MailBoxID, ma.name, ma.enablestoremanager, ll.loginname, ma.OwnerLoginID, ll.emailaddress,SUM(CAST(ME.Size AS BIGINT)) / 1024 / 1024 AS MailboxSizeMB
    FROM MailBox AS MA INNER JOIN
    MailBoxMessage AS MM ON MA.MailBoxID = MM.MailBoxID INNER JOIN
    Message AS ME ON MM.MessageID = ME.MessageID, Login AS LL
    where ma.OwnerLoginID=ll.LoginID
    group by ma.ownerloginid, ll.LoginID, ma.mailboxid,ll.loginname,ma.name, ll.EmailAddress, ma.EnableStoreManager