Back to EF FAQs Table of Contents
The Entity Framework does not provide a way to delete data in the database directly. You can pass commands directly to the database with the ExecuteStoreCommand method. You could use that to send a delete command. For other ways to perform this task, see Tip 9 Deleting an Object Without Retrieving It.
This post discusses the possible reasons why this problem may occur.
You can use ObjectQuery's ToTraceString method. For more information, see this forum thread or this quesiton on stack overflow. For tutorials that show how to view the SQL queries that EF generates, see Maximizing Performance with the Entity Framework in an ASP.NET Web Application (using ObjectContext) and Advanced Entity Framework Scenarios for an MVC Web Application (using DbContext). You might also want to take a look at the Entity Framework tracing provider.
Not yet. The June 2011 CTP version of EF includes a preview of TVF support. More details of the design are discussed here. The current plan is to include TVF support in the next major version of the .NET framework after 4.0.
The Entity Framework doesn't have that capability. We recommend that you use stored procedures or ExecuteStoreCommand to achieve executing CUD operations without bringing the entities into memory.
There is no built-in full-text search support. One way to achieve FTS is by using stored procedures. You can find some suggestions here.
Support for spatial data types is being added to the release following Entity Framework 4.1.
Not currently. There are plans to add support in future releases.
No. You can use SqlFunctions.DatePart instead. For more information, see this forum thread. Many datetime-related functions are available through the System.Data.Objects.EntityFunctions class.
The template is not included with Visual Studio but can be downloaded from the Visual Studio Gallery.
Yes. Code-first support was added to the Entity Framework 4.1 release.
The released versions of the Entity Framework (3.5 SP1 and 4) do not have magic columns. The code-first feature CTP currently has the convention that int columns that contain "Id" are treated as identity columns.
The following tutorials show you how to use ASP.NET MVC with the Entity Framework:
Diego B Vega edited Revision 8. Comment: formatting
Richard Mueller edited Revision 17. Comment: Removed (en-US) from title