title: How to use Oracle Entity Framework with no config file
body: <p>Is it possible to create a code-first Entity Framework model that connects to an existing database using ODP.Net without having any settings in the app.config file?</p>
  
  <p>I have tried many different things.</p>
  
  <p>Currently I am setting DbConfiguration:</p>
  
  <pre><code>    sealed class EntityFrameworkConfiguration : DbConfiguration
      {
          public static readonly DbConfiguration Instance = new EntityFrameworkConfiguration();
  
          EntityFrameworkConfiguration()
          {
              this.SetDefaultConnectionFactory(new OracleConnectionFactory());
              this.SetProviderServices("Oracle.ManagedDataAccess.Client", EFOracleProviderServices.Instance);
          }
      }
  
      DbConfiguration.SetConfiguration(EntityFrameworkConfiguration.Instance);
  </code></pre>
  
  <p>I am passing an <code>OracleConnection</code> directly into the EF context.</p>
  
  <p>However, I either have problems with the SQL being generated in SQL Server format (using double-quotes around table aliases), or I get the following error:</p>
  
  <pre><code>An unhandled exception of type 'System.NotSupportedException' occurred in EntityFramework.dll
  
  Additional information: Unable to determine the provider name for provider factory of type 'Oracle.ManagedDataAccess.Client.OracleClientFactory'. Make sure that the ADO.NET provider is installed or registered in the application config.
  </code></pre>
  
  <p>Has anyone any experience of getting this to work without polluting app.config with crud?</p>