Why same database file requires different SQL server localdb versions on different machines?

Arun Khatri 41 Reputation points
2023-05-01T09:03:51.1466667+00:00

How is it possible that on a development machine SSMS lists the database in SQL server version 13 but on production machine when I try to attach the database having installed SQL server version 13 gives error that the database is created in version 904 when it requires 852. Then I uninstalled the SQL server and installed SQL server 2019 Localdb on production machine and this time SSMS allowed to attach the same database file in version 15. I don't understand why the same database file requires different SQL versions on different machines. Please help to resolve this problem.

SQL Server | Other
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Erland Sommarskog 121.6K Reputation points MVP Volunteer Moderator
    2023-05-01T09:13:27.7133333+00:00

    It seems that there is some confusion on your side which SQL Server versions you have installed. If the database format version is 904, which means that the database was created on SQL 2019, so supposedly you have SQL 2019 locally.

    If you share a show a screenshot where you think you see that you have SQL 2016 locally, we might be able to straighten out more exactly where you confusion comes from.


  2. Arun Khatri 41 Reputation points
    2023-05-02T07:45:10.3066667+00:00

    I simply changed the value of the ParentInstance key from MSSQL13E.LOCALDB to MSSQL15E.LOCALDB in windows registry and it worked !!

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.