I have a ASP .Net project that I want to publish to Azure. At first, I did Enable-Migration and published the website by checking "Execute Code First Migration" check box in Publish Web dialog box in Visual Studio.
But I realized I am not using Code first approach since I have my DB already designed. I am using EF to create models for the database tables.
I deleted the Migrations folder from my project and republished the project WITHOUT checking the "Execute Code First Migration" for the database. But after publishing I still get this error:
What am i missing?
EDIT:
From web.config file:
<connectionStrings>
<add name="DefaultConnection" connectionString="Data Source=(LocalDb)\v11.0;AttachDbFilename=|DataDirectory|\aspnet-IMS2-20161228113511.mdf;Initial Catalog=aspnet-IMS2-20161228113511;Integrated Security=True" providerName="System.Data.SqlClient" />
<add name="IMSEntities" connectionString="metadata=res://*/Models.IMSEntities.csdl|res://*/Models.IMSEntities.ssdl|res://*/Models.IMSEntities.msl;provider=System.Data.SqlClient;provider connection string="data source=(localdb)\Projects;initial catalog=IMS;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" />
</connectionStrings>
From Azure portal. (Settings >> Application Settings >> Connection String). The name of the connection string in Azure is IMSEntitites.
Server=tcp:xxxxxxxxx.database.windows.net,1433;Initial Catalog=IMS;Persist Security Info=False;User ID=myUserName@xxxxxxxxx;Password=myPassword;MultipleActiveResultSets=True;Encrypt=True;TrustServerCertificate=False;Connection Timeout=30;