it:ad:code_first:home

IT:AD:Code First

  • Advantages:
  • Considerations:
    • Can begin work with Entities before a Db even exists.
    • Deployment is a different story.
  • Considerations:
    • Deployment has to be carefully considered [Deployment]
  • Disadvantages:
    • I disagree, but still:
        • Notably the following comment: “One thing to consider is what you are wanting out of code first. Are you really going for defining your tables in code and having that create the database, or is it the POCO aspect of EF 4.3 that you want? The reason I ask is that you could use POCOs and DbContext with Database First or Model First (you can create a custom T4 to gen the POCOs from your model). The reason I ask is because I sometimes see people writing about “code first”, when the thing that they are really after working with POCO/DbContext.”

      ## Requirements ##

  • Requires EntityFramework 4.2 +
  • Install:
    • Install Nuget
    • from the Nuget Command Prompt
      • Install-Package EntityFramework
  • Does the target Db have to have an EdmMetaInfo table?
    • No: it depends on the Strategy. If the strategy is to not check/create/rebuild a Db, then it won't check the Db.
  • /home/skysigal/public_html/data/pages/it/ad/code_first/home.txt
  • Last modified: 2023/11/04 03:22
  • by 127.0.0.1