I do not have ‘full’ the version of MS SQL (SQL Express 2008) so I do not have the profiler tool.
I want to see the SQL generated by my Entity Framework code, but all of the examples I find use the
var x = from u in table
select u;
type of syntax; But most of my queries are more like ..
var x = context.Users.Single(n => n.Name == "Steven");
type of syntax. What can I do to see the SQL generated, from this manner of coding? Any ideas?
Does Express Edition support extended events? If so this will capture statement and sp completed events in a similar way to Profiler.
Edit: I have changed it to use a memory target rather than a file target. Ideally uncomment the
WHEREsections and replace with an appropriate user name to capture only events of interest or you can filter by spid withWHERE (([sqlserver].[session_id]=(56)))for example.And to review the results (Query generated using Adam Machanic’s XE Code Generator)