Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8348681
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T07:45:56+00:00 2026-06-09T07:45:56+00:00

Using EF 4.0 i’m trying to do what i think should be dead simple

  • 0

Using EF 4.0 i’m trying to do what i think should be dead simple but it seems to be generating broken code.

  1. Create a new project (class library)
  2. add a new EF model and generate from a db (doesn’t matter what)
  3. Compile (all good)
  4. add a 2nd EF model and generate from a db (again, doesn’t matter what)
  5. Compile (breaks)

Can you only have a single EF model per assembly or something?

I’m not aware of any limitation … although it seems to put code in that breaks everything as soon as you add a second model.

Any ideas?

EDIT:

Ok i got round the problem by adding each EF model to a sub folder this generates the duplicate code still but puts it in a separate namespace … u’d think it would be smart enough to figure out the duplication … oh well.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T07:45:58+00:00Added an answer on June 9, 2026 at 7:45 am

    I never did completely get to the bottom of this but I figured out a work around which was to basically delete the project file and recreate it.

    Odd that it would affect EF like this though??

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using the navigator.geolocation object in JavaScript. Trying to establish accurate ranges, but wondering exactly
using Silverlight I am having trouble with the following code: CultureInfo culture = new
Using ValueInjecter, I often find myself writing code like this: var foo1 = new
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
Using linq2sql I'm trying to take the string in txtOilChange and update the oilChange
Using Rails 3.2.0 with haml, sass and coffeescript: Basically I am trying to disable
Using Jenkins or Hudson I would like to create a pipeline of builds with
Using Xcode4.2.1, with a basic PhoneGap template based app. (I say template, but I
Using Rails 3.2.0.rc2 and ruby 1.9.3p0 In app/views/requests/_form.html.erb I have the following code for
Using Entity Framework CodeFirst, how do I create a created datetime column that gets

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.