Home Forums SQL Server 7,2000 T-SQL Dynamic SQL, functions, stored procs - What are best practices? RE: Dynamic SQL, functions, stored procs - What are best practices?

  • Further investigation has shown a couple of things.

    First, I started experimenting with querying all of the values from CN=Partitions,CN=Configuration,DC=domain,DC=com and storing them in a temp table, however of the values that I'm interested in (nETBIOSName and dnsRoot), dnsRoot appears to be multi-valued. This appears to be a problem, as the ADSI provider for SQL doesn't seem to support multi-value attributes. Attempts to retrieve that value provide me the error:

    Msg 7346, Level 16, State 2, Line 3

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

    Second, it would appear to me that the general consensus for these kinds of question appears to be to use SQL CLR. This would also appear to be the same answer for my side question, relating to querying the rootDSE.

    Thanks again!