none
Entity Framework - Code First Bug RRS feed

  • Question

  • Not sure where to post a possible bug so I'm trying here.  I'm working with Entity Framework 5 using Code First with DBContext and no config file (all defaults).  I have SQL 2008 R2 with the default instance .\SQLEXPRESS installed and also SQL 2012 Express LocalDB (localdb)\v11.0.  The framework doesn't seem to be able to handle these side by side and throws an exception when I run my app.  I confirmed by removing SQL 2012 Express LocalDB and it works fine.  An interesting point is that when I run NuGet to install Entity Framework in either VS 2010 or VS 2012 it crashes VS and fails to install the framework.  My suspicion is that similar code is being used to find/select servers in both cases.  This post is intended to bring this to the attention of the Entity Framework team and not necessarily solve it here.  I'd be happy to provide any addtional data that the team might require.


    Donald Hofferber

    I found where the problem with NuGet may be exposed:

    "When you installed the EF NuGet package a default connection factory was registered that points to either SQL Express or LocalDb, depending on which one you have installed."

    • Edited by DDHSolutions Tuesday, September 11, 2012 10:47 PM
    Tuesday, September 11, 2012 7:35 PM

Answers

  • Hi Donald,

    If you think that this is a bug in EF then the best place to report it would be the codeplex site. http://entityframework.codeplex.com/WorkItem/Create

    The list of issues on Codeplex gets regularly triaged and assigned to people to work on, so it will definately get looked at by the team if it is there.

    The connect site linked to earlier is also used, as are these forums and other places that people can talk about issues, but they all end up being transferred to Codeplex eventually before they are worked on.

    As to your bug, I'm pretty sure I have a similar setup on one of my VMs and it works ok. So I suspect there is something in your environment causing this. However, that doesn't mean that EF shouldn't handle whatever that issue is. So let me know how you go.


    We are seeing a lot of great Entity Framework questions (and answers) from the community on Stack Overflow. As a result, our team is going to spend more time reading and answering questions posted on Stack Overflow. We would encourage you to post questions on Stack Overflow using the entity-framework tag. We will also continue to monitor the Entity Framework forum.


    Monday, September 17, 2012 6:43 PM
    Moderator

All replies

  • Hi Donald,

    Welcome to the MSDN forum.

    I am not very clear about this: The framework doesn't seem to be able to handle these side by side. Could you please let me know what handle means?

    Would you let me know what exception thrown? Specific message?

    Did you mean you installed EF from NuGet and Visual Studio crashed after you have uninstall SQL 2012?

    Good day.


    Alexander Sun [MSFT]
    MSDN Community Support | Feedback to us

    Thursday, September 13, 2012 3:03 AM
  • Hi,

    Try perhaps http://connect.microsoft.com/

    It's best to ALWAYS post the exception message (in case someone would have also an issue or would like to repro it or to search about it to attempt to help etc...)

    Not sure if related but if I remember with EF5 local DB is the default if installed. As it works when removed, could it be that you have some issue with your local db installation ?


    Please always mark whatever response solved your issue so that the thread is properly marked as "Answered".


    Thursday, September 13, 2012 11:42 AM
  • Thanks for the responses and suggestions.  Right now I suspect that the issue is my setup and not EF, NuGet or VS.  I've been upgrading Visual Studio from 2005 to 2008 to 2010 to 2012 and SQL from  2005 to 2008 R2 to 2012.  Plus many third party ad-ons.  I need to clean my system up and then try to re-create the problem if there is one.  Thanks again and I will report back with my findings.

    Donald Hofferber

    Thursday, September 13, 2012 2:49 PM
  • Hi Donald,

    If any problem occurs, please feel free to let us know.

    Good day.


    Alexander Sun [MSFT]
    MSDN Community Support | Feedback to us

    Friday, September 14, 2012 9:22 AM
  • Hi Donald,

    If you think that this is a bug in EF then the best place to report it would be the codeplex site. http://entityframework.codeplex.com/WorkItem/Create

    The list of issues on Codeplex gets regularly triaged and assigned to people to work on, so it will definately get looked at by the team if it is there.

    The connect site linked to earlier is also used, as are these forums and other places that people can talk about issues, but they all end up being transferred to Codeplex eventually before they are worked on.

    As to your bug, I'm pretty sure I have a similar setup on one of my VMs and it works ok. So I suspect there is something in your environment causing this. However, that doesn't mean that EF shouldn't handle whatever that issue is. So let me know how you go.


    We are seeing a lot of great Entity Framework questions (and answers) from the community on Stack Overflow. As a result, our team is going to spend more time reading and answering questions posted on Stack Overflow. We would encourage you to post questions on Stack Overflow using the entity-framework tag. We will also continue to monitor the Entity Framework forum.


    Monday, September 17, 2012 6:43 PM
    Moderator