<entityFramework>
<defaultConnectionFactory
type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework">
<parameters>
<parameter value="v11.0" />
</parameters>
</defaultConnectionFactory>
</entityFramework>
EDIT: QUESTION was reworded/reworked.
What does <parameter value="v11.0">
mean ? Or better Said Why Have just a Db Value?
What about using a full Data Source ?
And what is LocalDbConnectionFactory implying
These defaults are hard for me to understand.
Using the Sql default connection factory and parameter used SQL server LocalDbConnectionFactory did not work.
This did work:
<defaultConnectionFactory type="System.Data.Entity.Infrastructure.SqlConnectionFactory, EntityFramework">
<parameters>
<parameter value="Data Source=localhost; Integrated Security=True; MultipleActiveResultSets=True" />
The configuration section allows you to specify a default connection factory that Code First should use to locate a database to use for a context. The default connection factory is only used when no connection string has been added to the configuration file for a context.
The following configuration will cause Code First to use a LocalDB instance for contexts that don’t have an explicit connection string set.
<entityFramework>
<defaultConnectionFactory type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework">
<parameters>
<parameter value="v11.0" />
</parameters>
</defaultConnectionFactory>
</entityFramework>
Update : v11.0 is version of the LocalDb.
more info.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With