static void Main() { Database.SetInitializer(new MigrateDatabaseToLatestVersion<ArtistsDbContext, Configuration>()); var db = new ArtistsDbContext(); db.Artists.Count(); }
public SongController() { var db = new ArtistsDbContext(); this.songData = new EfGenericRepository<Song>(db); this.genreData = new EfGenericRepository<Genre>(db); this.artistData = new EfGenericRepository<Artist>(db); this.albumData = new EfGenericRepository<Album>(db); }
public CountryController() { var db = new ArtistsDbContext(); this.countryData = new EfGenericRepository<Country>(db); }
public ProducerController() { var db = new ArtistsDbContext(); this.producerData = new EfGenericRepository<Producer>(db); }