Home

EntityFramework 6 and Metadata

I'm trying to use my EF6 project with Linqpad, but when I test my connection, I get an error :

"Type is not resolved for member 'System.Data.Entity.Core.MetadatException'"

I've searched online and found only a handful of similar issues. I've tried adding dlls to my assembly folder, modifying the namespace in my connection string, and rebuilding my project. Nothing has worked. What am I missing?

Comments

  • After more research, I decided to try setting LINQPad to use the NuGet packages for EntityFramework that my project uses. The metatadata exception type apparently resolves now, but now I'm getting System.Data.Entity.Core.MappingException not resolving. Why is this happening?
  • In an attempt to see if the problem was really LINQPad, I created a new test project that connected to a different database server using EF6. Lo and behold, LINQPad connected with no problems. Turns out, the first database server was undergoing a restore, which means the errors I was getting was really an exception expressing itself incorrectly through an unfound exception type.

    Would it be possible to get some sort of connection error stack trace for this sort of thing? It'd make troubleshooting so much easier.
  • I've improved the error reporting in the 5.09.06 beta:
    https://www.linqpad.net/Download.aspx#beta

    It now reports nested inner exceptions and serializes the payload before transitioning application domains, so you don't lose anything. There's no stack trace, though - let me know if you still think this is important.
Sign In or Register to comment.