Hello everybody ::- ). I hope somebody wants some easy reputation by answering a simple question ::- ). How are you? Ok... joking ::- D.
The question is about how LINQ to Entities works with SQL Compact.
First of all, is there any way to profile stuff sent to an SQL Compact database? Apparently the Microsoft SQL Server Profiler does not work on SQL Compact databases... well... that's to be expected. But is there any other way to see the SQL query resulting from a LINQ select? Specifically:
IQueryable<some_table> query = from v in SomeEntity.some_table select v;
I am using some extension methods I found via Google to apply a "where" to the above select. Normally in Entity Framework you can't do that with LINQ (in .Net 3.5) but there are some workarounds.
What I want to do is verify if the workarounds get ALL the data from the table and then cheaply filter it, or if they are doing the RIGHT THING and only get the data that I asked for.
Secondly, do you know for sure that the statement below does NOT bring all the data in the table and puts it in memory after which does a cheap filter on it? (gosh I'd like a profiler to see what that dude is doing over there in the back-stage).
from v in SomeEntity.some_table where v.some_column == some_int_value select v;