问题描述
我想放置的.MDF数据库的计算机A
同时访问它计算机B
但我有,说因为它是被另一个进程无法访问MDF文件错误。
I'm trying to place a .mdf database on a Computer A
and access it simultaneously on Computer B
but I'm having an error that says I cannot access the mdf file because it's being used by another process.
的设置,数据库在公用文件夹托管计算机A
。我已经在两台计算机上运行Visual Studio和计算机B
访问计算机A上的数据库。
The setup is, the database is hosted on a Public folder in Computer A
. I have Visual Studio running on both computers, and Computer B
accesses the database on Computer A.
计算机的连接路径字符串:
Computer A Connection path string:
C:\\用户\\公用\\ database.mdf
C:\Users\Public\database.mdf
计算机B连接路径字符串:
Computer B Connection path string:
\\ 192.168.254.8 \\公用\\ database.mdf
\192.168.254.8\Public\database.mdf
是否有某种设置,我不知道,让一个分贝多址的?或者,这是不可能的?
Is there some sort of setting that I do not know of to enable multiple access on a db? Or this is not possible?
编辑:
让我改一下我的问题,对不起。
Let me rephrase my question, sorry.
有通过网络连接两台电脑,我想访问一个Visual Studio解决方案/项目的网站。我想做到这一点作为示范,这可能吗?
There are two computers connected via a network, and I want to access one Visual Studio solution/project website. I wanted to do this as a demonstration, is it possible?
推荐答案
任何 DBMS控制下同时或直接访问数据库文件或者一个极坏实践或根本不可能
Simultaneous or direct access to Database files under any DBMS control either a very bad practice or simply impossible.
使用适当的DBMS的工具来访问数据。
Use proper DBMS tools to access the data.
是的 - 它可以访问网站项目演示
And yes - its possible to access Web site project for demo.
这篇关于单密度纤维板数据库上的多个连接(ASP.net)的SQL Server的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!