I use ODBC to connect to my SQL server database. My connection string only contains a data source name, username and password. There is no server name variable in the connection string. This is useful because the server name would be different on my local testing environment and my remote host.
I have just started using the web wiz forum tools, the instructions say i must change the database_connection.asp page, specifying a string value for my server name. I don't even know what the server name is on the remote host, so I just left it blank and then hardcoded the connection string to my 3 variable ODBC connection string.
I then followed through the rest of the instructions, the 'msSQL_server_setup.asp' worked perfect, it was able to connect to my database no problem and create the neccesary forum tables (I actually had to hardcode the connection string on that page aswell)
However when I got to the next step of actually logging into the forum, it threw up an error:
Server Error in Forum Application An error has occurred while connecting to the database. Please contact the forum administrator.
Support Error Code:- err_SQLServer_db_connection File Name:- common.asp
Error details:- Microsoft OLE DB Provider for SQL Server Invalid connection string attribute
|
It is one of those customized error pages, which is really annoying because it does not give me the line number in the code where it errored. But what is the problem? How do I connect to the database using ODBC? I have no problem connecting to my database on my own webpages using the same hard coded connection string.
Ideally I want to change the code on the forum pages very little, because i do not want to edit a bunch of code that i do not know what its purpose is.