We used to use SQL 2000 but have moved upto 2005, below is the typical connection string I used to connect to 2000 and worked fine;
objConn = "PROVIDER=SQLOLEDB;DATA SOURCE=STARGATE\STARBASE;UID=sa;PASSWORD=password;DATABASE=WEBBILL"
Below is a couple of examples of connection strings I used to connect to 2005:
objConn = "Provider=SQLNCLI;Server=MAGGIE\MAGGIE;Database=WEBBILL;Uid=sa;Pwd=password;"
objConn = "Provider=SQLOLEDB;Data Source=192.168.0.51:1433; Initial Catalog=webbill; User ID=sa; Password=parssword;"
but on any variation I get the following error:
Microsoft OLE DB Provider for SQL Server error '80004005'
[DBNETLIB][ConnectionOpen (ParseConnectParams()).]Invalid connection.
/main.asp, line 23
I'm not sure if my connections are incorrect or if it's a setup within SQL 2005