Geeks With Blogs

Post Categories

James Norman
More of a note to myself, but it may help someone else out too.

Been brushing up on EF lately, and as such the Pluralsight courses I've been going through use LocalDB with Entity Framework.  Of course, I'd rather use my local default instance of SQL Server.  So I had to change a couple of things within app.config, underlined below. 

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <configSections>
    <!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
    <section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
  </configSections>
  <entityFramework>
    <defaultConnectionFactory type="System.Data.Entity.Infrastructure.SqlConnectionFactory, EntityFramework">
      <parameters>
        <parameter value="Data Source=.; Integrated Security=True; MultipleActiveResultSets=True"  />
      </parameters>
    </defaultConnectionFactory>
    <providers>
      <provider invariantName="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer" />
    </providers>
  </entityFramework>
</configuration>
Posted on Thursday, August 11, 2016 3:11 PM Entity Framework , SQL Server , EF 6.0 | Back to top


Comments on this post: Changing the Entity Framework (EF) Configuration to Use SQL Server Instead of LocalDB

No comments posted yet.
Your comment:
 (will show your gravatar)


Copyright © James Norman | Powered by: GeeksWithBlogs.net