chicken
chicken

Reputation: 1640

Getting description field from Active Directory in SQL Server 2005 (LDAP)

The only field I cannot grab is the description field from our AD. The error is:

Cannot get the data of the row from the OLE DB provider "ADsDSOObject" for linked server "ADSI". Could not convert the data value due to reasons other than sign mismatch or overflow.

Is there some datatype I can use to handle the object it is trying to return?

Upvotes: 2

Views: 3085

Answers (2)

TheSavo
TheSavo

Reputation: 583

I have the same problem getting the Description field from AD while attempting to use ADsDSOObject and ADO.

you have to inter-ate through the values with a For Each or Do until ... EOF type of statement.

Here is a good example

Upvotes: 0

marc_s
marc_s

Reputation: 754983

I guess your problem is the fact that AD can store multiple values in a single field (quite contrary to the very first normalization rule in relational databases).

Not sure what your query looks like - but could you possibly try to add a "[0]" indexer to the description attribute, by any chance??

Marc

Upvotes: 1

Related Questions