Hi Dian, One thing, if you're using NT authentication, you do not pass a username and password. That is for SQL authentication, such as with the "sa" account. Also, you're not specifying a database to use. While this is not necessary, if you don't have the correct default database set for the user, you'd have to execute a "USE databaseName" before querying (or query with fully-qualified object names). And if you're installation of SQL Server is on a machine called DIANSMICRON, and has a SQL instance of DIANSQLSERVER, your connection string would look like this. (I think.)
"Provider=sqloledb;Data Source=DIANSMICRON\DIANSQLSERVER;Initial Catalog=YourDatabaseNameHere;Integrated Security=SSPI;" Ray at home > -----Original Message----- > From: Dian D. Chapman [mailto:[EMAIL PROTECTED] > Sent: Thursday, March 17, 2005 11:10 PM > To: Group - ASP > Subject: [ASP] Trouble connecting to SQL > > > I'm trying to setup a test connection (using Word) to an SQL > server. I do this all the time with Access, but haven't had > to mess with an SQL server for sometime...and I'm having trouble. > > * I setup the SQL server on my PC using SQL Personal Ed 2000. > > * I'm almost positive the ConnString is right: > > "Provider=SQLOLEDB;Data Source=diansmicron;user > id=dian;password=myPassword" > > ...where the source is the name of my PC (is that right or > should it be the server name?...which would be > diansmicron\diansqlserver) > > ...where "dian" is both the user name for the server AND the > WinNT logon user > > ...where "myPassword" is my WinNT logon for my PC...which, if > I understand correctly, it what it wants due to WinNT > security being set. The server pass is different, but I've > tried both (in every possible combination) and I'm getting > the following error... > > Run-time error '-2147467259 (80004005)': > > [DBNETLIB][ConnectionOpen (Invalid Instance()).]Invalid connection. > > I'm at a loss to troubleshoot this...and not too good with > servers.<sigh> Can anyone offer any suggestions about how to > debug or fix this? > > Does that error tell me my conn string has a problem...or it > is saying something else is the problem???? > > TIA for any help... > > Dian ~ > > -- > This email scanned and certified clean by AVG! > Checked by AVG Anti-Virus. > Version: 7.0.308 / Virus Database: 266.7.2 - Release Date: 3/11/2005 > > > > > -------------------------------------------------------------- > ------- > Home : http://groups.yahoo.com/group/active-server-pages > --------------------------------------------------------------------- > Post : [email protected] > Subscribe : [EMAIL PROTECTED] > Unsubscribe: [EMAIL PROTECTED] > --------------------------------------------------------------------- > Yahoo! Groups Links > > > > > > > > --------------------------------------------------------------------- Home : http://groups.yahoo.com/group/active-server-pages --------------------------------------------------------------------- Post : [email protected] Subscribe : [EMAIL PROTECTED] Unsubscribe: [EMAIL PROTECTED] --------------------------------------------------------------------- Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/active-server-pages/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
