SqlExpress mdf 数据库不兼容
我在我的网站之一中使用了 ASP.NET (.NET4) 默认 ASPNETDB.mdf 数据库,该数据库是在使用成员身份时创建的。然后我将该网站复制到网络服务器。现在已经运行了一段时间了,有了内容和评论。但我现在需要对代码进行更改,这也需要数据库中的额外字段,因此我将 .mdf 从服务器复制到本地计算机以编辑和添加字段(所以我没有丢失内容等)。但是当我替换 mdf 后运行项目时,出现以下错误:
“数据库 “.....APP_DATA\ASPNETDB.MDF”不能 打开是因为它是661版本。这个 服务器支持版本 655 和 早些时候。降级路径不是 支持。无法打开用户默认值 数据库。登录失败。登录失败 对于用户“Me-PC\Me”。
这让我很困惑,因为它正是我的家庭 VS 生成的 mdf 文件。服务器也运行与我相同的.NET,所以我不明白为什么它会改变任何东西。
谢谢!
I used the ASP.NET (.NET4) default ASPNETDB.mdf database that gets created when using membership, in one of my sites. I then copied the site to the web server. Now it has been running for a while so there is content and comments. But I now need to make changes to the code that will also require extra fields in the db, so I copied the .mdf from the server to my local machine to edit and add the fields(so I didnt lose content etc). But when I run the project after replacing the mdf i get the following error:
"The database
".....APP_DATA\ASPNETDB.MDF" cannot be
opened because it is version 661. This
server supports version 655 and
earlier. A downgrade path is not
supported. Cannot open user default
database. Login failed. Login failed
for user 'Me-PC\Me'.
This confuses me, as it is the exact mdf file that my home VS generated. The server is running the same .NET as I am too, so I dont see why it would have changed anything.
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好吧,事实证明服务器正在运行不同版本的 MSSql Server 2008 R2(是吗?),这意味着 db 文件正在升级,所以当它返回到我的低级系统时它失败了。必须卸载并重新安装 VS 2008 和 SQL Server 2008
Ok, so it turns out the server was running a different version of MSSql Server 2008 R2 (yeah?) which meant that the db file was getting upgraded, so when it came back to my lowly system it failed. Had to uninstall and reinstall both VS 2008 and SQL Server 2008