Advertisement

07.26.2007 at 08:27AM PDT, ID: 22723068
[x]
Attachment Details

Query Active Directory for Date an account is Disabled

Asked by kendingo in Active Directory, Windows 2000 Operating System

Tags: active, directory, disabled, query, date

Hello Experts,

I am trying to find out a way to query AD using the ADU&C interface in a way that will show me the disabled accounts that were disabled before a specific date.
Basically i need to know what the field or userAccountControl code is, if there is one at all.

I curentlly have a saved query to gather all my disabled users which looks like this:
   (&(objectCategory=person)(objectClass=user)(userAccountControl:1.2.840.113556.1.4.803:=2))

I also played around with a query that would give me all my disabled users created before a specific date which looks like this:
   (&(&(objectCategory=person)(objectClass=user)(userAccountControl:1.2.840.113556.1.4.803:=2)
   (whenCreated>=20050801000000.0Z)))
   This query does not quite meet my needs but gets me closer to the end goal.

Any help would be great.
DingoStart Free Trial
[+][-]07.26.2007 at 02:22PM PDT, ID: 19578442

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Active Directory, Windows 2000 Operating System
Tags: active, directory, disabled, query, date
Sign Up Now!
Solution Provided By: Chris-Dent
Participating Experts: 1
Solution Grade: A
 
 
[+][-]07.27.2007 at 04:35AM PDT, ID: 19581467

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.27.2007 at 04:37AM PDT, ID: 19581476

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32