jamorlando
asked on
Exporting AD Contacts with Powershell
Hi,
I'm currently trying to migrate our company's 1000+ mail contacts from Exchange into a contacts list in Sharepoint.
I need specific data from Active Directory for each contact which goes beyond what the Get-MailContact cmdlet can do. I need info like Company, phone number...etc...
I downloaded Quest's tools, but it seems like their cmdlets are only for users, not contacts.
Any ideas?
I'm currently trying to migrate our company's 1000+ mail contacts from Exchange into a contacts list in Sharepoint.
I need specific data from Active Directory for each contact which goes beyond what the Get-MailContact cmdlet can do. I need info like Company, phone number...etc...
I downloaded Quest's tools, but it seems like their cmdlets are only for users, not contacts.
Any ideas?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
you mean StreetAddress?
get-contact -resultsize unlimited | select-object name,Phone,company,streeta ddress
again try with on one conact get-contact contactname | fl and you will be able to find all properties
get-contact -resultsize unlimited | select-object name,Phone,company,streeta
again try with on one conact get-contact contactname | fl and you will be able to find all properties
ASKER
Actually Ken, when I run
Get-QADObject -type contact -Identity bjones | fl
I don't see an attribute for address either. Is there a way to do this from quest?
Get-QADObject -type contact -Identity bjones | fl
I don't see an attribute for address either. Is there a way to do this from quest?
here are the address attributes in get-contact
StreetAddress
PostOfficeBox
City
StateOrProvince
PostalCode
CountryOrRegion
StreetAddress
PostOfficeBox
City
StateOrProvince
PostalCode
CountryOrRegion
Try it with -includedproperties *
Get-QADObject -type contact -Identity bjones -includedproperties * | fl *
Get-QADObject -type contact -Identity bjones -includedproperties * | fl *
ASKER
Thanks ... I got this figured out. I'm going to give you guys all credit, cause all 3 of you were very helpful.
ASKER
@xxdcmast, wow, never heard of the csvde.exe command, but that's pretty sweet that you can do this kind of thing from the command prompt instead of powershell. If I can't get Ken's solution to work I'll check this out.
@Akhater, I see company, and phone, but what about an attribute like "Address" which is stored in AD?