Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.databases.ms-sqlserver > #803

Re: test connection to a database without specifying a database

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail
From Erland Sommarskog <esquel@sommarskog.se>
Newsgroups comp.databases.ms-sqlserver
Subject Re: test connection to a database without specifying a database
Date Tue, 15 Nov 2011 14:12:30 +0000 (UTC)
Organization Erland Sommarskog
Lines 27
Message-ID <Xns9F9E9AB5A976Yazorman@127.0.0.1> (permalink)
References <4ec26862$0$294$14726298@news.sunsite.dk>
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
Injection-Date Tue, 15 Nov 2011 14:12:30 +0000 (UTC)
Injection-Info mx04.eternal-september.org; posting-host="G7+Jz22XqYCG8C6rb1H3YA"; logging-data="27309"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18yn30zADC7WrVZtcVRtnL9"
User-Agent Xnews/2005.10.03 Mime-proxy/1.4.c.4 (Win32)
Cancel-Lock sha1:reqP0FCQQHSWiqyLMcirsJDf/Pk=
Xref x330-a1.tempe.blueboxinc.net comp.databases.ms-sqlserver:803

Show key headers only | View raw


Tony (johansson.andersson@telia.com) writes:
> I do the following.
> 1.Right click on Data Connection in Server Explorer and choose Add 
> connection
> 2. In the Data Source I select Microsoft SQL Server (SqlClient)
> 3.In server name I enter localhost
> 4. I select Use Window Authentication
> 5. I click on Test Connection and the result is Test connection succeeded
> 
> Now to my question I really don't understand how this is possible to test 
a 
> connection
> without specifying any database ?
> Can somebody explain that.
 
This is because that SQL Server stores a default database for you, which you 
will be connected to if you do not specify a database. By default this 
default database is the master database.


-- 
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx

Back to comp.databases.ms-sqlserver | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

test connection to a database without specifying a database "Tony" <johansson.andersson@telia.com> - 2011-11-15 14:25 +0100
  Re: test connection to a database without specifying a database Erland Sommarskog <esquel@sommarskog.se> - 2011-11-15 14:12 +0000
    Re: test connection to a database without specifying a database "Tony" <johansson.andersson@telia.com> - 2011-11-15 15:14 +0100
  Re: test connection to a database without specifying a database "Bob Barrows" <reb01501@NOyahooSPAM.com> - 2011-11-15 09:15 -0500

csiph-web