title: Connection String For .Net Core application from .Net Standard Entity Framework 6.0
body: <p>I am a newbie in .Net Core,</p>
  <p>I am always using .Net Framework to develop an application (Web App / Web API).
  I have develop my custom Framework and it already established. my custom framework use Entity Framework 6.0  (DB First)
  Now, I have assigned to develop Web Api in .Net Core. but still use my custom framework to process the data.
  on .net core web api I need to assign connection string like web api on .net standard
  In .Net Standard my Connection string like below</p>
  <pre><code>  &lt;connectionStrings&gt;
    &lt;add name=&quot;CompanyEntities&quot;
      connectionString=&quot;metadata=res://*/CompanyModel.csdl|res://*/CompanyModel.ssdl|res://*/CompanyModel.msl;provider=System.Data.SqlClient;provider connection string=&amp;quot;data source=127.0.0.10;initial catalog=XYZ;persist security info=True;user id=sa;password=zzzxxx123!;multipleactiveresultsets=True;application name=EntityFramework&amp;quot;&quot;
      providerName=&quot;System.Data.EntityClient&quot;/&gt;
  </code></pre>
    
  <p>for application using .Net Standard Framework (WebApp/ WebApi)... there is no Issue with this. it runs normally</p>
  <p>but I don't know, how I can set connection string on .Net Core? please help</p>
  <p>I have tried connection string like this but failed</p>
  <pre><code>
      &quot;ConnectionStrings&quot;: {
      &quot;CompanyEntities&quot;: &quot;Data Source=127.0.0.10;Database=xyz;uid=sa;pwd=zzzxxx123!;MultipleActiveResultSets=true;Integrated Security=False&quot;
    }
  </code></pre>
  <p>this is the error :</p>
  <p>Severity    Code    Description Project File    Line    Suppression State
  Error   CS0311  The type 'Classes.Model.Data.Library.CompanyEntities' cannot be used as type parameter 'TContext' in the generic type or method 'EntityFrameworkServiceCollectionExtensions.AddDbContext(IServiceCollection, Action, ServiceLifetime, ServiceLifetime)'. There is no implicit reference conversion from 'Clasess.Model.Data.Library.CompanyEntities' to 'Microsoft.EntityFrameworkCore.DbContext'.</p>
  <p>and this my dbcontext</p>
  <pre><code> public partial class CompanyEntities : DbContext
  {
      public CompanyEntities()
          : base(&quot;name=CompanyEntities&quot;)
      {
      }
  
      protected override void OnModelCreating(DbModelBuilder modelBuilder)
      {
          throw new UnintentionalCodeFirstException();
      }
  </code></pre>