简体   繁体   中英

Using data connections in Visual Studio to explore SQL Server Express database

I am using Entity Framework in order to create my models, but when I try to access the database from the data connections in Server Explorer, it does not work. I know the models are being created in the SQL Server Express instance running on my local machine, as I navigated to

Computer -> Program Files -> Microsoft SQL Server -> MSSQL10.SQLEXPRESS -> MSSQL -> DATA ->

and the database is in there.

在此处输入图片说明

Shouldn't my local instance of SQL Server Express show up in this window?

在此处输入图片说明

I read over this article from Microsoft which explains where database is stored.

Under server name type in \\\\\\SQLEXPRESS or .\\SQLEXPRESS (assuming you have installed the instance with default values)

then you should be able to access the database from the dropdown list.

you need to select your machine name from the Server Name dropdown as shown in below picture.

在此处输入图片说明

if your server is not showing in the list then simply open SQL Server note down that Server Name and write it Manually.

Here is an Example

在此处输入图片说明

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM