Solved

Powershell Get-ADUser URL field

Posted on 2011-09-19
7
1,434 Views
Last Modified: 2012-05-12
I am trying to export some data from AD using powershell. Need the following information:

Firstname, lastname, email, phone, company, url

I can pull all the data above except for the URL field. It displays on screen, but doesn't export. I have:

get-aduser -Properties givenname,surname,enabled,emailaddress,office,officephone,url | export-csv test.csv
0
Comment
Question by:rsn-helpdesk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
7 Comments
 
LVL 27

Expert Comment

by:KenMcF
ID: 36562966
use wwwhomepage

get-aduser -Properties wwwhomepage, givenname,surname,enabled,emailaddress,office,officephone | Select wwwhomepage, givenname,surname,enabled,emailaddress,office,officephone | export-csv test.csv
0
 

Author Comment

by:rsn-helpdesk
ID: 36562995
Clarifying... URL is Web Page Other, and not the same as wwwhomepage. When you display on screen the URL field, it displays, but for some reason it won't export to csv. I assume because you can have multiple URL fields?
0
 
LVL 13

Expert Comment

by:Govvy
ID: 36563012
Use Quest AD Module and run:

>Get-QADUser -objectAttributes @[www}
0
Free NetCrunch network monitor licenses!

Only on Experts-Exchange: Sign-up for a free-trial and we'll send you your permanent license!

Here is what you get: 30 Nodes | Unlimited Sensors | No Time Restrictions | Absolutely FREE!

Act now. This offer ends July 14, 2017.

 

Author Comment

by:rsn-helpdesk
ID: 36563089
Govvy, that still doesn't export the URL field.
0
 
LVL 27

Expert Comment

by:KenMcF
ID: 36563114
yeah, that is a multi valued attribute. It is a little harder to get them into a csv file. Do users have more than 1 url attribute? I can post something later tonight if no one posts before that

0
 

Author Comment

by:rsn-helpdesk
ID: 36563128
KenMcF: For most, there is only 1 url attribute. Very few have 2 url attributes.
0
 
LVL 13

Accepted Solution

by:
Govvy earned 500 total points
ID: 36563193
Change the output to csv type on this command:

>Get-QADUser -DontUseDefaultIncludedProperties -ObjectAttributes @{homeDirectory='*'} -IncludedProperties 'url' | fl url
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A project that enables an administrator to perform actions within a user session context not just at the time of login but any time later on day(s) or week(s) later.
My attempt to use PowerShell and other great resources found online to simplify the deployment of Office 365 ProPlus client components to any workstation that needs it, regardless of existing Office components that may be needing attention.
This tutorial will give a short introduction and overview of Backup Exec 2012 and how to navigate and perform basic functions. Click on the Backup Exec button in the upper left corner. From here, are global settings for the application such as conne…
This tutorial will walk an individual through the steps necessary to install and configure the Windows Server Backup Utility. Directly connect an external storage device such as a USB drive, or CD\DVD burner: If the device is a USB drive, ensure i…

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question