‎11-02-2020 11:03 AM
Solved! Go to Solution.
‎11-03-2020 03:56 PM
Select Top 1000000 tblADusers.Username,
extension2.Value As ExtensionAttribute2,
tblADusers.OU,
tblADusers.whenCreated,
tblADusers.whenChanged,
tblADusers.PasswordLastSet,
tblADusers.Lastchanged,
tblADusers.LastLogon
From tblADusers
Left Join (Select tblAdProperty.Value,
tblAdProperty.AdObjectId
From tblAdProperty
Inner Join tsysAdPropertyType On tsysAdPropertyType.TypeId =
tblAdProperty.TypeId
Where tsysAdPropertyType.Name = 'ExtensionAttribute2') As extension2 On
extension2.AdObjectId = tblADusers.ADObjectID
Where extension2.Value Like '%%'
Order By Case
When tblADusers.Displayname Is Null Or
tblADusers.Displayname = '' Then tblADusers.Userdomain + '\' +
tblADusers.Username
Else tblADusers.Displayname
End,
tblADusers.Userdomain,
tblADusers.Username
‎11-03-2020 04:10 PM
‎11-03-2020 03:06 PM
‎11-03-2020 03:15 PM
Andy.S wrote:
Is this what your after - https://www.lansweeper.com/knowledgebase/active-directory-user-and-computer-attributes-scanned-by-lansweeper/
‎11-03-2020 03:56 PM
Select Top 1000000 tblADusers.Username,
extension2.Value As ExtensionAttribute2,
tblADusers.OU,
tblADusers.whenCreated,
tblADusers.whenChanged,
tblADusers.PasswordLastSet,
tblADusers.Lastchanged,
tblADusers.LastLogon
From tblADusers
Left Join (Select tblAdProperty.Value,
tblAdProperty.AdObjectId
From tblAdProperty
Inner Join tsysAdPropertyType On tsysAdPropertyType.TypeId =
tblAdProperty.TypeId
Where tsysAdPropertyType.Name = 'ExtensionAttribute2') As extension2 On
extension2.AdObjectId = tblADusers.ADObjectID
Where extension2.Value Like '%%'
Order By Case
When tblADusers.Displayname Is Null Or
tblADusers.Displayname = '' Then tblADusers.Userdomain + '\' +
tblADusers.Username
Else tblADusers.Displayname
End,
tblADusers.Userdomain,
tblADusers.Username
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now