Comparison and applicable scenarios of EF provider for access/ODBC and ADO. NET Entity Framework and LINQ to SQL:

Source: Internet
Author: User
1. When selecting datasource in my environment vs2008 sp1.entity Data Model Wizard, the Acess database cannot be selected. Is the acess Entity Data Model currently unavailable.
On the contrary, you can use LINQ to SQL.

2. What are the advantages of ADO. NET Entity compared with LINQ to SQL? for small and medium projects and their adaptation

A:

1. So far, EF provider for access/ODBC has not been officially released by Microsoft.
The data provider of ADO. NET Entity Framework can be customized based on different target databases. The key to provider development is the translation of SQL statements suitable for each target database. On msdn code Gallery, there is an instance developed by Entity Framework sample provider.Program, The following links are for reference.
A. http://code.msdn.microsoft.com/EFSampleProvider; Entity Framework sample provider
B. http://code.msdn.microsoft.com/EFOracleProvider sample Entity Framework provider for Oracle-home
C. http://blogs.msdn.com/adonet/; team blog for ADO. net, with a lot of information about EF or provider Publishing.

2. ADO. comparison between NET Entity Framework and LINQ to SQL and applicable scenarios:
an article published by ELISA flasko, , compared the applicable scenarios of LINQ to SQL and LINQ to entities:
introducing LINQ to Relational Data
http://msdn2.microsoft.com/en-us/library/cc161164.aspx
the author pointed out that, the main application scenarios of LINQ to SQL are the rapid development of Microsoft SQL Server databases. The object models of these applications are very similar to the data-defined structures in databases, there is almost a one-to-one ing relationship, so that you can map some data tables directly. net class, Data Fields are mapped to the corresponding. Net class attributes. The author summarizes the following:
applicable scenarios of LINQ to SQL
. I want to use the ORM scheme, and the database data definition corresponds to the object model at
. I want to use the ORM scheme, and the Object Inheritance structure is stored in a single data table (single table inheritance)
. to use the original CLR class, instead of using the generated class or inheriting from a base class, or implement an interface
. I want to write a query using LINQ
. I want to use Orm, but it requires excellent performance, performance can be optimized through stored procedures and compiled queries.
the main application scenarios of LINQ to entities are scenarios that require flexible and more complex ing, especially for enterprise applications, access to other database systems is also required. In these scenarios, the data table structure and object model may be very different, and application developers often do not have the right to generate or modify database data definitions.
applicable scenarios of LINQ to entities:

. You want to develop applications for Microsoft SQL Server or other database systems.
. You want to define the domain model and use it as the basis of the persistent layer.
To use the orm scheme, the object may have a correspondence with the database data definition, and the structure may be different.
. You want to use an ORM solution that supports single-Table inheritance and other storage solutions (one table for each type and one table for each specific type ).
. If you want to write a query using LINQ, and the query can work in different Database Systems
. If you want to use Orm, but the performance is very good, You can optimize the performance through the stored procedure and compiled query.

Liu jiangtao [MSFT]
Online Development Support Engineers
Partner Support Department
Microsoft Global Technical Support Center

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.