852版本打不开.本服务器支持782及更早版本

Cannot be opened because it is version 852. this server supports version 782 and earlier(852版本打不开.本服务器支持782及更早版本)
本文介绍了852版本打不开.本服务器支持782及更早版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Visual Studio 2017 和 SQL Server 2014.在将数据库文件附加到 Visual Studio 时,我收到此错误:

I am using Visual Studio 2017 and SQL Server 2014. While attaching a database file to Visual Studio, I get this error:

""

升级文件后我使用了这个连接字符串

After upgrading the file I used this connection string

<connectionStrings>
    <add name="con" 
         connectionString="Data Source=(LocalDB)MSSQLLocalDB;AttachDbFilename=|DataDirectory|inaaelmamorra.mdf;Integrated Security=True;Connect Timeout=30"/>
</connectionStrings>

它在我的机器上运行良好,但在客户端机器上,弹出一个错误提示

It's working fine on my machine, but on the client machine, an error pops up saying

无法打开,因为是852版本.本服务器支持782及更早的版本

Cannot be opened because it is version 852. This server supports version 782 and earlier

虽然我在客户端安装了 SQL Server 2016 本地数据库,但我仍然无法摆脱它.

Though I installed SQL Server 2016 local DB on the client side, I still can't get rid of it.

我的第二个问题是:数据库文件不兼容的SQL Server当前实例是什么?

My second question is: what is the current instance of SQL Server to which the database file is not compatible?

推荐答案

这对我有用:

  1. 打开命令提示符并输入:

  1. open command prompt and type :

cd "C:Program FilesMicrosoft SQL Server130LocalDBBinn"

  • 在cmd中运行此命令删除本地数据库:

  • Run this command in cmd to delete the local db :

    SqlLocalDB.exe delete "MSSQLLocalDB"
    

    (或 SqlLocalDB.exe 停止MSSQLLocalDB",如果您收到实例仍在运行的错误)

    (or SqlLocalDB.exe stop "MSSQLLocalDB", if you get an error of intance still running)

    然后输入此命令以创建本地数据库的新更新实例:

    Then type in this command to create a new updated instance of local db :

    SqlLocalDB.exe create "MSSQLLocalDB"
    

  • 参考:https://www.youtube.com/watch?v=bCjc9Mmx-bM

    这篇关于852版本打不开.本服务器支持782及更早版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

    本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

    相关文档推荐

    DispatcherQueue null when trying to update Ui property in ViewModel(尝试更新ViewModel中的Ui属性时DispatcherQueue为空)
    Drawing over all windows on multiple monitors(在多个监视器上绘制所有窗口)
    Programmatically show the desktop(以编程方式显示桌面)
    c# Generic Setlt;Tgt; implementation to access objects by type(按类型访问对象的C#泛型集实现)
    InvalidOperationException When using Context Injection in ASP.Net Core(在ASP.NET核心中使用上下文注入时发生InvalidOperationException)
    LINQ many-to-many relationship, how to write a correct WHERE clause?(LINQ多对多关系,如何写一个正确的WHERE子句?)