cancel
Showing results for 
Search instead for 
Did you mean: 

Gets Vaults/EV Users where the Mailbox was deleted

Rajesh_Velaga1
Level 4

Below Query is not working.

 

Is that possible to find archives assciated to disabled accounts and deleted mailboxes?

 

Link:  http://www.enterprisevaultfaq.com/wiki/Query_Orphaned_Vaults

Source

Execute in EnterpriseVaultDirectory Database

SELECT * FROM ExchangeMailboxEntry WHERE LegacyMbxDn LIKE '%marked%'
1 ACCEPTED SOLUTION

Accepted Solutions

Wayne_Humphrey
Level 6
Partner Accredited Certified

 

Hi Rajesh,

 

The Archiving State translates as follows:

0 = Not Enabled 1 = Enabled 2 = Disabled 3 = Re-Link

To view the Archiving State you can use the following:

SELECT count(MbxArchivingState) as '# Mailboxes', MbxArchivingState as 'Archiving State' FROM ExchangeMailboxEntry GROUP BY MbxArchivingState

The Exchange State translates as follows: 

0 = Normal 1 = Hidden 2 = Deleted

To view the Exchange State you can use the following:

SELECT count(MbxExchangeState) as '# Mailboxes', MbxExchangeState as 'Exchange State' FROM ExchangeMailboxEntry GROUP BY MbxExchangeStateAlso check out this:

https://www-secure.symantec.com/connect/downloads/get-all-list-all-none-enabled-mailboxes-and-all-re...

View solution in original post

7 REPLIES 7

Wayne_Humphrey
Level 6
Partner Accredited Certified

 

Hi Rajesh,

 

The Archiving State translates as follows:

0 = Not Enabled 1 = Enabled 2 = Disabled 3 = Re-Link

To view the Archiving State you can use the following:

SELECT count(MbxArchivingState) as '# Mailboxes', MbxArchivingState as 'Archiving State' FROM ExchangeMailboxEntry GROUP BY MbxArchivingState

The Exchange State translates as follows: 

0 = Normal 1 = Hidden 2 = Deleted

To view the Exchange State you can use the following:

SELECT count(MbxExchangeState) as '# Mailboxes', MbxExchangeState as 'Exchange State' FROM ExchangeMailboxEntry GROUP BY MbxExchangeStateAlso check out this:

https://www-secure.symantec.com/connect/downloads/get-all-list-all-none-enabled-mailboxes-and-all-re...

MichelZ
Level 6
Partner Accredited Certified

Hi

 

The query you mentioned is only to find archives which are "marked for deletion".

Wayne's query will get you what you want.

 

Cheers


cloudficient - EV Migration, creators of EVComplete.

Rajesh_Velaga1
Level 4

Thanks All!

 

is it possible to list all disabled EV archives?

 

Regards

Rajesh

MichelZ
Level 6
Partner Accredited Certified

SELECT * FROM ExchangeMailboxEntry WHERE MbxArchivingState = 2

This lists you all disabled archives.

Cheers


cloudficient - EV Migration, creators of EVComplete.

Rajesh_Velaga1
Level 4

Thanks Michel!

 

I need help with query for below combination.

MbxExchangeState = 2 & MbxArchivingState =1

MichelZ
Level 6
Partner Accredited Certified

SELECT * FROM ExchangeMailboxEntry WHERE MbxArchivingState = 1 AND MbxExchangeState = 2


cloudficient - EV Migration, creators of EVComplete.

Rajesh_Velaga1
Level 4

Thanks Michel!

 

Will I be able to delete archives using below query?

 

SELECT     *
 
FROM         ExchangeMailboxEntry
 
WHERE     MbxArchivingState = 1 AND MbxExchangeState = 2

GO
 

 
UPDATE Archive
 
SET ArchiveStatus = 4

GO