Quantcast
Channel: patterns & practices: Project Silk
Viewing all articles
Browse latest Browse all 93

New Post: How do you enable database Seeding?

$
0
0

Hi,

Have you checked if you are setting the corresponding IDatabaseInitializerwhen the application starts by calling the Database.SetInitializer method inGlobal.asax.cs - Application_Start(). For example inMilageStats this can be seen in the constructor of the RepositoryInitializerclass:

Database.SetInitializer(new DropCreateIfModelChangesSqlCeInitializer<MileageStatsDbContext>());

Which is run, when calling the InitializeDatabase method in Application_Start() of the Global.asax.cs file.

Also, regarding this topic I believe you could also find the following step by step tutorial interesting:

I hope this helps,

Agustin Adami
http://blogs.southworks.net/aadami


Viewing all articles
Browse latest Browse all 93

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>