Active Directory User Details Sync to SQL Server

Hi,

I need to develop an application that will automatically sync user details from many Active Directories into a SQL Database. Any help on this will be really appreciated. I am developing in VB.NET or C#.

Thanks
LVL 2
avineshpAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Mark WillsTopic AdvisorCommented:
Well, you can create linked servers, but not if the remote servers are not part of a trusted domain. So, then you might need to explore first creating a csv and then import those.

But, from your central SQL server you can import via a stored procedure (or SSIS package) the required information in either format.

So, you code would first create the AD export and then call the SQL import.

I havent needed to play with this for a while, and there are no doubt some wonderous Powershell examples out there... But to get you started check out :

There are samples around like : http://technet.microsoft.com/en-us/library/cc720650(WS.10).aspx
and an older one going directly to AD from SQL : http://codebetter.com/brendantompkins/2003/12/19/create-a-sql-server-view-of-your-ad-users/

Creating the csv's in the first place you do have a few options - one such is : http://www.petri.co.il/using-csvde-ldifde-export-active-directory-snapshots-windows-server-2008.htm and using the LDIFDE utility : http://support.microsoft.com/kb/555636

You might like to describe your environment a bit more, and also what tools / experience and editions/versions you are using.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Active Directory

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.