Entity Framework Core Feature Suggestions

Welcome! Use this web site to submit ideas and vote for what features you want to see in future versions of Entity Framework Core.

Our team will only fix bugs, implement small improvements and accept community contributions in the EF6 codebase. Larger feature work and innovation will happen only in the EF Core codebase. If you have ideas for improving EF6, we recommend you submit them on the EF6 GitHub site listed below.

Please also consider these other options before submitting anything to this site:

  • If you want to learn how to use our products, visit our documentation pages.
  • If you want to report bugs, make contributions, or learn about our product roadmaps, visit our EF Core or EF6 project pages on GitHub.
  • If you have technical questions or need help, try StackOverflow’s EF Core or EF6 tags. Note that roadmap questions, bug reports, feature requests or ideas are not appropriate for StackOverflow. Visit StackOverflow’s help center for guidance on appropriate usage.

How can we improve Entity Framework Core?

(thinking…)

Enter your idea and we'll search to see if someone has already suggested it.

If a similar idea already exists, you can support and comment on it.

If it doesn't exist, you can post your idea so others can support it.

Enter your idea and we'll search to see if someone has already suggested it.

  1. Visual Studio diagram designer

    A full fledged diagram designer that allows editing the EF Core model using boxes and lines metaphor rather than code. Where you can add/update/remove tables and views from an existing database.

    3 votes
    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)

      We’ll send you updates on this idea

      0 comments  ·  Flag idea as inappropriate…  ·  Admin →
    • Support tuples in query expressions

      With the introduction of first-class support for tuples in C#7, Entity Framework should add support for tuples inside query expressions along.
      SO issue here: http://stackoverflow.com/questions/17595105/use-tuples-with-entity-framework-contains-statement

      The lack of support for this is super frustrating, especially since anonymous classes are not supported in EF either, and from a performance perspective this is simply a fixed number of values being passed into a query (ie: should not be any more complex to execute on the DB).

      For example, the following should work but is currently not supported:

      IEnumerable<string> identifers = /*get from somewhere*/....;

      Tuple<string, string>[] identifierPairs = originIdentifers.Select( _ => {
      string[]…

      3 votes
      Sign in
      Check!
      (thinking…)
      Reset
      or sign in with
      • facebook
      • google
        Password icon
        I agree to the terms of service
        Signed in as (Sign out)

        We’ll send you updates on this idea

        0 comments  ·  Flag idea as inappropriate…  ·  Admin →
      • Improved API for Migrations

        The API for DbMigrator is lacking. I would like to see .UpOne(), .DownOne(), .Up(n), .Down(n) methods to attempt to perform that number of migrations.

        .Update("0") is an odd-looking way to completely thrash the DB. Something like .RollbackAll() would be a very simple implementation and have a much clearer name.

        Having .Update() take an additional optional parameter to completely rollback first, and apply all migrations from scratch might be very nice, especially in a test or development environment.

        Generating an SQL script for logging purposes and then performing the DB migration must currently (I believe) be done in two steps. A…

        3 votes
        Sign in
        Check!
        (thinking…)
        Reset
        or sign in with
        • facebook
        • google
          Password icon
          I agree to the terms of service
          Signed in as (Sign out)

          We’ll send you updates on this idea

          1 comment  ·  Flag idea as inappropriate…  ·  Admin →
        • Support Pessimistic Concurrency

          Allow a Select with UpdLock which locks all returned entities in the Database. This is a basic requirement to program for example a ticket sales portal with entity framework! So far it's not possible and I still have to stick to NHibernate :(

          3 votes
          Sign in
          Check!
          (thinking…)
          Reset
          or sign in with
          • facebook
          • google
            Password icon
            I agree to the terms of service
            Signed in as (Sign out)

            We’ll send you updates on this idea

            0 comments  ·  Flag idea as inappropriate…  ·  Admin →
          • 3 votes
            Sign in
            Check!
            (thinking…)
            Reset
            or sign in with
            • facebook
            • google
              Password icon
              I agree to the terms of service
              Signed in as (Sign out)

              We’ll send you updates on this idea

              1 comment  ·  Flag idea as inappropriate…  ·  Admin →
            • Add attribute for federated tables

              Add a "FederatedOn" attribute to the "Table" data annotation so Code First entities can be associated to a SQL Azure Federations federated member. For instance: [Table("Pessoas", FederatedOn = "TenantId=TenantId")]
              As an alternative, allow an equivalent attribute to be declared on the entity property that is the federation distribution key (e.g. the TenantId property).

              3 votes
              Sign in
              Check!
              (thinking…)
              Reset
              or sign in with
              • facebook
              • google
                Password icon
                I agree to the terms of service
                Signed in as (Sign out)

                We’ll send you updates on this idea

                0 comments  ·  Flag idea as inappropriate…  ·  Admin →
              • More descriptive error message when using non-generated POCO - Mapping and metadata information

                Need more detail as to why EF gives this excpetion "Mapping and metadata information could not be found for EntityType". Usually it is a name mismatch, but with large modesl it can be hard to pinpoint the source of the error.

                3 votes
                Sign in
                Check!
                (thinking…)
                Reset
                or sign in with
                • facebook
                • google
                  Password icon
                  I agree to the terms of service
                  Signed in as (Sign out)

                  We’ll send you updates on this idea

                  0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                • Custom mapping for complex types

                  Suppose I have a complex type called "Address". I also have two entities, one called "Customer" with a "Street1" property, and a second called "Business" with an "Address1" property. Being able to map these entity properties to the same complex type would be helpful even though the property names do not match.

                  3 votes
                  Sign in
                  Check!
                  (thinking…)
                  Reset
                  or sign in with
                  • facebook
                  • google
                    Password icon
                    I agree to the terms of service
                    Signed in as (Sign out)

                    We’ll send you updates on this idea

                    0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                  • Clear all entities in a set

                    Need to be able to call Clear on an EntitySet to delete all entities from that set (i.e. rows from underlying table). When called as myObjectContext.MyCustomers.Clear() it would delete all rows in the underlying table.

                    3 votes
                    Sign in
                    Check!
                    (thinking…)
                    Reset
                    or sign in with
                    • facebook
                    • google
                      Password icon
                      I agree to the terms of service
                      Signed in as (Sign out)

                      We’ll send you updates on this idea

                      1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                    • Support optional complex type

                      For example: Class Foo has a property named Bar and that property is a reference to the complex type ComplexBar. It would be great if Bar could be left null in cases when a "user/whatever" does not have any ComplexBar information. The benefit is that ComplexBar can have required properties and other validation that only applies when the property Bar is not null. If it is null then that validation is not triggered because it does not apply. If I want Bar to always have a value then I can flag it as required, and it will behave like complex…

                      3 votes
                      Sign in
                      Check!
                      (thinking…)
                      Reset
                      or sign in with
                      • facebook
                      • google
                        Password icon
                        I agree to the terms of service
                        Signed in as (Sign out)

                        We’ll send you updates on this idea

                        1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                      • Allow inserting new entities with predefined identity column values (INSERT_IDENTITY)

                        Especially for migration projects it would be useful to allow entities to be saved with predefined identity values.

                        Until now you have to use ADO.NET to do this.
                        SET IDENTITY_INSERT TableName ON
                        INSERT INTO TableName (IdColumn, Column1)
                        VALUES (234, 'Value')

                        I would like to tell the DbContext to use this feature when saving new entities.

                        3 votes
                        Sign in
                        Check!
                        (thinking…)
                        Reset
                        or sign in with
                        • facebook
                        • google
                          Password icon
                          I agree to the terms of service
                          Signed in as (Sign out)

                          We’ll send you updates on this idea

                          0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                        • Allow stored procedures to be used to navigate relationships

                          There are many developers who are in shops that don't allow non-stored procedure calls to SQL Server. It would be really nice if there was something in EF where we could select a relationship in the EF designer, go to its mapping and select a stored procedure for each role in the relationship. It might go something like this:

                          1.We would create a relationship between two entitties, say Author and Book. Both entities would be required to expose foreign keys (the developer can make them private if they want).
                          2.A stored procedure would be created that would navigate from each…

                          3 votes
                          Sign in
                          Check!
                          (thinking…)
                          Reset
                          or sign in with
                          • facebook
                          • google
                            Password icon
                            I agree to the terms of service
                            Signed in as (Sign out)

                            We’ll send you updates on this idea

                            0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                          • Change schema for DbContext per connection

                            Build one model from code first and then use new TennantContext(connection, schema).

                            Exactly as HasDefaultSchema but possible to change with new connection.

                            No migrations and no other special features needed.

                            Lets say I have users data stored in one DB but in different schemas (each user has own schema). I have 1000+ of users, every model for every user is cached by IDbModelCacheKeyProvider is RAM kill.

                            P.S. Alter user set default schema is not a solution

                            Thanks

                            3 votes
                            Sign in
                            Check!
                            (thinking…)
                            Reset
                            or sign in with
                            • facebook
                            • google
                              Password icon
                              I agree to the terms of service
                              Signed in as (Sign out)

                              We’ll send you updates on this idea

                              0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                            • Code First (EF6) Ignore certain properties so they aren't mapped to stored procedures

                              When mapping Properties to Stored Procedure parameters it is not possible to ignore any properties that the Stored Procedure doesn't require/isn't expecting e.g. a field that the DBMS populates. In the example below the DateCreated property is defaulted in the DBMS to the current date/time so isn't required as a parameter, but is to be shown on the blog post UI so needs to be part of the model. Ideal would be to have an IgnoreParameter option

                              public class Blog
                              {
                              public int BlogId { get; set; }
                              public string Name { get; set; }
                              public string Url { get;…

                              3 votes
                              Sign in
                              Check!
                              (thinking…)
                              Reset
                              or sign in with
                              • facebook
                              • google
                                Password icon
                                I agree to the terms of service
                                Signed in as (Sign out)

                                We’ll send you updates on this idea

                                2 comments  ·  Flag idea as inappropriate…  ·  Admin →
                              • A Collection which automatically sets the parent property on add

                                class Product {
                                Category Category;
                                }
                                class Category {
                                [ParentProperty("Category")]
                                ParentHashSet Products
                                }

                                var prod = new Product();
                                var cat = new Category();

                                cat.Products.Add(prod);
                                Assert.AreEqual(cat, prod.Category);

                                3 votes
                                Sign in
                                Check!
                                (thinking…)
                                Reset
                                or sign in with
                                • facebook
                                • google
                                  Password icon
                                  I agree to the terms of service
                                  Signed in as (Sign out)

                                  We’ll send you updates on this idea

                                  0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                                • Mapping n to n relation in a table with discriminator like TPH

                                  The most interesting side effect of TPH is that the DB need less tables and the overview is much better. Another interesting way to reduce the number of tables in a DB is to map the n to n relations in one table with a discriminator like the TPH.
                                  The xsd schema allow already to add a condition to the associated set mapping (n to n) but it's not supported from EF.
                                  This forum topic describe the problem and how it could be solved.
                                  http://social.msdn.microsoft.com/Forums/en-US/adodotnetentityframework/thread/7144757d-c124-4932-b2bf-d0ab845597fd

                                  3 votes
                                  Sign in
                                  Check!
                                  (thinking…)
                                  Reset
                                  or sign in with
                                  • facebook
                                  • google
                                    Password icon
                                    I agree to the terms of service
                                    Signed in as (Sign out)

                                    We’ll send you updates on this idea

                                    0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                                  • Better support for mainframe databases like DB2

                                    Please add support for connecting to and using mainframe databases like DB2. We can't wait for IBM to get their act together and produce a usable EF provider.

                                    3 votes
                                    Sign in
                                    Check!
                                    (thinking…)
                                    Reset
                                    or sign in with
                                    • facebook
                                    • google
                                      Password icon
                                      I agree to the terms of service
                                      Signed in as (Sign out)

                                      We’ll send you updates on this idea

                                      0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                                    • Support for Linked SQL Servers

                                      Add support for Linked servers.

                                      3 votes
                                      Sign in
                                      Check!
                                      (thinking…)
                                      Reset
                                      or sign in with
                                      • facebook
                                      • google
                                        Password icon
                                        I agree to the terms of service
                                        Signed in as (Sign out)

                                        We’ll send you updates on this idea

                                        1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                                      • Method to get context from entity

                                        some times we need to know the context from entity

                                        3 votes
                                        Sign in
                                        Check!
                                        (thinking…)
                                        Reset
                                        or sign in with
                                        • facebook
                                        • google
                                          Password icon
                                          I agree to the terms of service
                                          Signed in as (Sign out)

                                          We’ll send you updates on this idea

                                          1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                                        • Migrations: Allow Multiple Migration SQL Generator per Provider

                                          One way to allow community to contribute to EF Migrations is allow us to create more `MigrationOperation`s.

                                          For example, people can then add things like full text index, etc., things that are not in the core EF Migrations and are just boring SQL statements that need to be combined together.

                                          Currently, to build a provider agnostic `MigrationOperation`, you need to write the SQL generated for the operation in a class derived from `MigrationSqlGenerator`. If you want to add `CreateFullTextCatalog` operation and support SQL Server for example, you inherit `SqlServerMigrationSqlGenerator`, add a `Generate` method for your operation, and ensure all other…

                                          3 votes
                                          Sign in
                                          Check!
                                          (thinking…)
                                          Reset
                                          or sign in with
                                          • facebook
                                          • google
                                            Password icon
                                            I agree to the terms of service
                                            Signed in as (Sign out)

                                            We’ll send you updates on this idea

                                            0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                                          • Don't see your idea?

                                          Entity Framework Core Feature Suggestions

                                          Feedback and Knowledge Base