Hi, When you connect to SQL Server from an application you need to specify which database you want to use - that's what the DB name is for. If you don't specify a name you end up in the "default database" configured for the user in question.
If you need to reference objects in other databases, other than the one you are in, you need to use a fully qualified object name: dbname.ownername.objectname (e.g. exec otherdatabase.dbo.sprocname) Cheers Ken From: Joseph L. Casale [mailto:[email protected]] Sent: Thursday, 5 March 2009 9:00 AM To: NT System Admin Issues Subject: SQL2k DB name Question When I use Enterprise Mangler and check the properties of a DB, I can see for both the db and log "filename" which shows its name, and "location" which shows its actual filename. When I use Query Analyzer and execute a sp_helpfile I see "name" which matches "file name" and "filename" which matches "location". Odd naming convention... Anyway, what is the significance of the db name? I have an app that creates a db upon installation with a name of "A" but the db for which I am restoring from uses a name of "B"? Thanks! jlc ~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ <http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/> ~
