Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_databases thread: Postscript to 'Server breaking Access DSNs'


Message #1 by "Marcus Hamilton" <marcus@p...> on Wed, 12 Sep 2001 19:11:02 +0100
Dear All,



This is a postscript to an earlier message that said:



I'm converting over to SQL Server 2000 from Access 97, but after having

installed SQL, none of my Access ODBC DSNs work.



The operating system I'm using is Windows Server 2000 Advanced.



I get the following error:



"Microsoft OLEDB Provider for ODBC Drivers (0x80004005) [Microsoft][ODBC

Driver Manager] Data source name not found and no default driver specified."



I assuming that it is possible to run applications that use Access and

applications that use SQL Server on the same server.



The way that I'm trying to access the data in the script is:



set ors = Server.CreateObject("ADODB.Recordset")

ors.open "tableName","dsnName",adOpenKeyset,adLockOptimistic,adCmdTable





I have since discovered that whilst:



set ors = Server.CreateObject("ADODB.Recordset")

ors.open "tableName","dsnName",adOpenKeyset,adLockOptimistic,adCmdTable



does not work since installing SQL Server 2000



the following does:



set oConn = Server.CreateObject("ADODB.Connection")

oConn.open "dsnName"

set ors = oConn.Execute("SELECT fieldName FROM tableName")



The Recordset connection did work before SQL server was installed. I can't

change all of my connections to use the Connection object because of legacy

code.



Help would be much appreciated.



Regards



Marcus








  Return to Index