Although you could, at least theoretically, use
ExecuteStoreCommand() to run queries on the server, doing so doesn’t make much sense, because the method only returns the number of records affected, not the records themselves. For querying, the
ObjectContext class exposes the
ExecuteStoreQuery<T>() method, and the equivalent
DbSet<T> method is
Take A Break
We’ve only just touched the surface of the capabilities both
DbContext provide for executing commands directly on the server. It’s not ...