Jump into our new React Basics course 😎

Learn about our new Community Discord server here and join us on Discord here!

Probe The AI Multiverse: Exploring the Subfields of Artificial Intelligence 😮

Get job-ready with our Career Toolbox Track's career advice, resume tips, and more 🧰

New course: AI Tools for Designers 🎨✨

Students: got a cool project or resource to share? Submit it to Treehouse Links! 🤩

Learn about our new Community Discord server here and join us on Discord here!

🤖 Check out all our AI content here 👀

  • Home
  • Free Trial
  • Sign In
  • Plans
  • Tracks
  • Library
  • Community
  • Support
  • Jobs
    • Newest
      • Newest
      • Active
      • Unanswered
      • Featured
    • All Topics
      • All Topics
      • • General Discussion
      • • 21st Century Skills
      • • AI
      • • Android
      • • APIs
      • • Business
      • • C#
      • • Computer Science
      • • CSS
      • • Data Analysis
      • • Databases
      • • Design
      • • Development Tools
      • • Digital Literacy
      • • Equity, Diversity, and Inclusion (EDI)
      • • Go Language
      • • HTML
      • • Java
      • • JavaScript
      • • Learning Resources
      • • Machine Learning
      • • PHP
      • • Python
      • • Quality Assurance
      • • React
      • • Ruby
      • • Security
  • olu adesina
    olu adesina
    23,007 Points

    where im i going wrong with Database.SetInitializer

    Posted June 24, 2018 5:46pm by olu adesina
    olu adesina
    23,007 Points
    • C#
    • Entity Framework Basics
    • Entity Framework and Databases
    • Controlling Database Generation

    1 Answer

  • Joe Mackey
    Joe Mackey
    20,418 Points

    In Context.cs add a default constructor that sets the database initializer to an instance of the DropCreateDatabaseAlway

    Posted June 3, 2017 7:10pm by Joe Mackey
    Joe Mackey
    20,418 Points
    • C#
    • Entity Framework Basics
    • Entity Framework and Databases
    • Controlling Database Generation

    2 Answers

  • Joe Mackey
    Joe Mackey
    20,418 Points

    In Context.cs add a default constructor that sets the database initializer to an instance of the DropCreateDatabaseAlway

    Posted June 1, 2017 10:22pm by Joe Mackey
    Joe Mackey
    20,418 Points
    • C#
    • Entity Framework Basics
    • Entity Framework and Databases
    • Controlling Database Generation

    1 Answer

Posting to the forum is only allowed for members with active accounts.
Please sign in or sign up to post.

    Treehouse

  • About
  • Blog
  • Careers
  • Community
  • Stories
  • Shop
  • Contact
  • Gift Card

See Full Catalogue

Techdegree

  • Front End Web Development
  • Full Stack JavaScript
  • Python Development
  • Data Analysis
  • UX Design

Tracks

  • Learn to Code for Beginners
  • Beginning Python
  • Beginning SQL
  • Beginning Java
  • ...see more

Courses

  • JavaScript Basics
  • Intro to HTML & CSS
  • Python Basics
  • CSS Layout
  • ...see more

Explore

  • Plans
  • Perks
  • Public Library Access
  • Treehouse for Libraries
  • Treehouse for Businesses
  • Twitter
  • YouTube
  • Facebook
  • LinkedIn
  • Instagram
Terms & Conditions | Privacy

© 2023 Treehouse Island, Inc.