I'm using LINQ to Entities. I need to log the resulting SQL of every executed query. It'd be nice to log the execution times and the number of rows returned, though it's not crucial.
Is there a way to do this from within the app? I'd rather not use the SQL Profiler.
There should be a way to trace everything that goes from the framework to database. I can't modify every single usage of entity framework (so ToTraceString or some custom method call before iterating through results isn't an option) - it has to be a single solution working throghout the app.