cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Arron
Engaged Sweeper II
Hi,

I am looking for what table the data "Active Directory Extension Attributes" against a user are stored in so i can add them to a report?

Thanks,
Arron
1 ACCEPTED SOLUTION
Andy_Sismey
Champion Sweeper III
Hi Arron,

So I think this should work for you, I have ammended one I use for Attrib10 :

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

View solution in original post

4 REPLIES 4
Arron
Engaged Sweeper II
Hi Andy,

That is perfect, thank you very much.

Arron
Andy_Sismey
Champion Sweeper III
Is this what your after - https://www.lansweeper.com/knowledgebase/active-directory-user-and-computer-attributes-scanned-by-lansweeper/
Arron
Engaged Sweeper II
Andy.S wrote:
Is this what your after - https://www.lansweeper.com/knowledgebase/active-directory-user-and-computer-attributes-scanned-by-lansweeper/


Hi Andy,

Thank you, Kind of i can see the attributes and vales when i view a user but i am trying to pull "ExtensionAttribute2" in to a report but cannot find what table it is stored in?

Thanks,
Arron
Andy_Sismey
Champion Sweeper III
Hi Arron,

So I think this should work for you, I have ammended one I use for Attrib10 :

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

New to Lansweeper?

Try Lansweeper For Free

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

Try Now