error 0152: No Entity Framework provider found for the ADO.NET provider with invariant name 'System.Data.SqlClient'. Make sure the provider is registered in the 'entityFramework' section of the application config file. See http://go.microsoft.com/fwlink/?LinkId=260882 for more information.
Is this error keep on destroying your life and blowing your mind?
Don't worry, you are not alone!
It turns out that you just need to configure your cs project because you have relied too much with the Nuget Package Manager.
The Entity Framework 6 is a cool tool that all of us wanted to use. Through the Nuget, the EF will be added to your project. However, it turns out, the Copy Local property of the reference to these files:
EntityFramework.dll
EntityFramework.SqlServer.dll
are not set to true.
To fix this, set the Copy Local to False, save the project, and then set back to True.
I found from the Stackoverflow, that you may also need to put this line inside your DBContext's initialize method of your Data Entities project.
var ensureDLLIsCopied = System.Data.Entity.SqlServer.SqlProviderServices.Instance;




