Question: I want to practice with some database that I want to use inside Visual Studio 2017.

I had `Northwind.mdf` that I downloaded some time ago. But when I try to connect to it from VS2017 Servers panel, I get error message:

> 
> This database file is not compatible with the current instance of SQL Server.
> 
> 
> 

Q1: Why?

Q2: Where and how do I know the version of `Northwind.mdf`?

Q3: Where and how do I know which version of database is supported by VS2017?

Q4: I can create my own database in VS2017, but why I cannot use the existing database?

Answer: 
SQL Server only supports databases up to two versions ago, I don't know what version of SQL Server comes with VS2017 but I suppose that is at least SQL Server 2016 (you can check it using the query `select @@version`), so it supports at most DB's from SQL Server 2012 and [Northwind is for SQL Server 2000](https://www.microsoft.com/en-us/download/details.aspx?id=23654).

If you *really, really* want to use that database you have an upgrade path, is a bit cumbersome but is free (you should use a virtual machine for this if you can, I sometimes use [the VM's that MS offer for testing IE](https://developer.microsoft.com/en-us/microsoft-edge/tools/vms/) for this sort of things):

* Download and install [SQL Server 2008 R2 Express](https://www.microsoft.com/en-us/download/details.aspx?id=30438), which is the last version that supports databases from SQL Server 2000. Import the database and make a full backup (you can also attach and detach the database files but I prefer to use backups).
* If the version returned by `select @@version` if SQL Server 2016 or higher, download and install [SQL Server 2014 Express](https://www.microsoft.com/en-us/download/details.aspx?id=53167). Restore the backup from 2008 to a new database and then make another backup of that database (if you are using this version just restore the backup in your current SQL Server and you are done).
* Finally, restore the 2014 backup in the SQL Server used by VS2017.

Note that is you already have SQL Management Studio (or it's integrated in VS2017) you don't need to install the previous versions, since it can connect to different SQL Server versions (if you do all the installs on your system you *shouldn't* install the previous versions of Management studio, take care of this). Also, if you are doing this in your system I recommend uninstall the step versions as soon as possible.
i have the same problem, i want to use the northwind in VS2017 environment.

(btw - [w3scools](https://www.w3schools.com/sql/)use this northwind db to teach sql (october 2018)

so i download the sql script from [here](https://learn.microsoft.com/en-us/dotnet/framework/data/adonet/sql/linq/downloading-sample-databases), install it and run it from **cmd** in my computer

**sqlcmd -S (localdb)\mssqllocaldb -i InstNwnd.sql**

This create db in my computer that i can access by **sqlcmd**, and by visual studio 2017.

If you want those files (without build it yourself) you can download it from my [google drive](https://drive.google.com/drive/folders/1hsajv_kfkdC18Zvl1evzWiM4lpNDHDC9?tid=0B_-9ztMxDLr7UGZSTDBKQXk2blU) ( i will upload it to github someday and change the link)