Code-First (2)

How To: Refresh POCO entity from DbContext

If you notice that the context returns the same entity even if it is already changed one line before, you probably what the following

You can use it right after obtaining an entity with a statement like follows:


Not obvious issues in configuration of EF Code First

This post describes my own issues which I bumped into while setting up EF Code First. This is not a complete list of all possible issues and any input would be appreciated. Connection String In web project it may be not obvious why is database not created. The error message may tell about the null reference […]