Writing Entity Framework generated SQL to Visual Studio output window

Claus Sørensen

Using a powerful ORM like Entity Framework is great. But once in a while when debugging, not having access to the generated SQL can be a real pain. Fortunately Entity Framework comes with handy logging functionality. What I do is to wire Entity Framework up for outputting logging information to…