Migrations Asp Net MVC

Asked

Viewed 72 times

1

I did a project first feeding my application ASP.Net MVC by an SQL Server database that I have uploaded to the web.config file (connectionString).

Then, following some courses I did, I started using Migrations to update the database tables. Problem is that I am checking that he is no longer looking at the table and database that are set in my web.config. I did a test, deleted my connectionstring from my web.config file and the application keeps running and connecting with the bank without problems.

I’m not understanding where is set the database and tables that he is looking at, I realized that it is no longer in my web file.config. Need to know to do some checks on the data in the SQL Server database.

1 answer

0


When you do not specify a connection string, the Entity Framework creates an internally pointed string for your Localdb and with the database name equal to yours DbContext

Search your (localdb)\MSSQLLocalDB a base with the name in this fomato MinhaSolucao.MinhaAplicacao.Contexts.MeuDbContext

  • I managed to locate, thank you.

  • If the answer made you locate, please mark it as correct

Browser other questions tagged

You are not signed in. Login or sign up in order to post.