Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
schinni
Yak Posting Veteran
66 Posts |
Posted - 2003-03-31 : 20:33:23
|
| Is there a way we can query active directory from Sql Server 2000i want to query and get some data from active directory and load intosql2k,right now this is done using visual basic.Thanks in advance. |
|
|
efelito
Constraint Violating Yak Guru
478 Posts |
Posted - 2003-04-01 : 10:00:31
|
| You can setup a linked server to AD and use it to run queries. I've done it against Exchange. Here is what I used to create a linked server connection to exchange.sp_addlinkedserver @server = 'ADSI', @srvproduct = 'Active Directory Service Interfaces', @provider = 'ADSDSOObject', @datasrc = 'adsdatasource'gosp_addlinkedsrvlogin @rmtsrvname = 'ADSI', @useself = 'FALSE', @rmtuser = null, @rmtpassword = nullgoYou will need to do some hunting around to get the query syntax just right, but that should get you started.Jeff BanschbachConsultant, MCDBA |
 |
|
|
|
|
|