Solved

Microsoft Sql Server 2005 - Same DB Name but different file locations

Posted on 2014-11-21
5
186 Views
Last Modified: 2014-11-21
I have a program that uses sql server 2005.  I did not write it, its an app from our vendor.  It was made to run alone on a users PC.  I'd like to deliver the app through Xenapp.  What I'd like to know is: Can you have the same DB name but different filenames?  I'd like to store the files (MDF, LDF) on a shared drive using the %USERNAME% variable.  That way everyone's data would be unique to them.  We cannot share the DB.  
So my thought was we start a single Sqlserver and load the DB's (Same name but different filenames) so that everyone has access their own data.
Or when each user logs in we have multiple Sqlserver instances running.  Not sure what that would do to performance.  We have vSphere 5.1 - Citrix 7.1 - Sqlserver 2005.
0
Comment
Question by:Daves166
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 50

Expert Comment

by:Vitor Montalvão
ID: 40457396
No, you can't have databases with same name in the same instance.
But you can have same database name in several instances and the performance just depends on your server (mainly RAM is the more important here, then CPU).
0
 

Expert Comment

by:mw 162
ID: 40457397
You cannot have the same database name with different file names on the same instance. Is it possible to package a SQL Express instance into the virtual application?
0
 
LVL 50

Expert Comment

by:Vitor Montalvão
ID: 40457411
We cannot share the DB.  
Then why have the database on a server? Just install a SQL Server Express instance locally in each user computer.
0
 

Author Comment

by:Daves166
ID: 40457419
IT is not my App so I cannot do the Sql Express mentioned above.  However, I may be able to create multiple instances.  Can you create a named instance programmatically?
0
 
LVL 50

Accepted Solution

by:
Vitor Montalvão earned 500 total points
ID: 40457431
You need to run the SQL Server setup each time you need to create an instance. Means that you always need to install SQL Server.
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SQL Query with Sum and Detail rows 2 68
Replace Dates in query 14 57
Clone table from one server.database to another server.database 24 61
What is this datetime? 1 33
by Mark Wills Attending one of Rob Farley's seminars the other day, I heard the phrase "The Accidental DBA" and fell in love with it. It got me thinking about the plight of the newcomer to SQL Server...  So if you are the accidental DBA, or, simp…
Introduction This article will provide a solution for an error that might occur installing a new SQL 2005 64-bit cluster. This article will assume that you are fully prepared to complete the installation and describes the error as it occurred durin…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question