Entity Framework Feature Suggestions

Welcome! You can use this site to tell the EF team what features you want to see in future versions of our products.

Note that moving forward our team will be only fixing bugs, implementing small improvements, and accepting community contributions in the EF6 codebase. Larger feature work and innovation will happen in the EF Core codebase.

Please consider other options besides this site!

  • If you have technical questions or need help, try StackOverflow (EF6 and EF Core) or visit our forums.
  • If you want to learn how to use our products, visit our documentation pages: EF6 and EF Core.
  • If you want to report bugs or make contributions, visit our project pages on GitHub: EF6 and EF Core.

How can we improve Entity Framework or Entity Framework Core?

You've used all your votes and won't be able to post a new idea, but you can still search and comment on existing ideas.

There are two ways to get more votes:

  • When an admin closes an idea you've voted on, you'll get your votes back from that idea.
  • You can remove your votes from an open idea you support.
  • To see ideas you have already voted on, select the "My feedback" filter and select "My open ideas".
(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. Complex (struct) key properties for tables with multiple primary keys. Enabling easier search by key

    Some tables have more than one field included in primary key.

    This makes definition of generic methods that search by key hard to implement.

    If it would be possible to combine all database keys into one struct in model, and enable T4 templates to recognize which property is the key, template-generated repository could be much more powerful.

    4 votes
    Vote
    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)
      You have left! (?) (thinking…)
      0 comments  ·  Flag idea as inappropriate…  ·  Admin →
    • More options in Code-First db generation

      There should be more control on the generated Database:
      - Default values,
      - Relationship names,
      - Description fields should/shouldn't be gererated (according to metadata/xml documentation in the entities)
      - Constraints
      - Propery enum types should be automatically generated to the underlying enum type (enum AddressType : byte should be stored as byte)

      61 votes
      Vote
      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)
        You have left! (?) (thinking…)
        2 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
      • Bring back CompiledQuery in DbContext

        CTP 5 dropped compiled query support, this is a huge mistake. Please make sure it is there in the final product.

        210 votes
        Vote
        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)
          You have left! (?) (thinking…)
          12 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
        • Formulas in properties / calculated properties

          Allow having properties that contain the result of formulas. The formula should be specified in a new attribute or fluently.

          1 vote
          Vote
          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)
            You have left! (?) (thinking…)
            0 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
          • Richer collection support, including ordered collections and dictionaries of value types

            It would be very nice to be able to support properties which are collections of value types. Just to have an array of doubles I shouldn't need to map each value to a class. NHibernate has this feature. E.g.
            class Benchmark
            {
            public long Id {get; set;}
            public string Name {get; set;}
            public IDictionary<DateTime, double> Returns {get; set;}
            public int[] Vector {get; set;} // preserve the order too
            }

            99 votes
            Vote
            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)
              You have left! (?) (thinking…)
              6 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
            • Conditional table splitting with 1 to 0..1 relationship.

              Sometimes I want to move one or more properties of an entity to a separate class.

              This is possible with a 1 to 1 relationship, however, there is no option to do this with a 1 to 0..1 relationship, where if the properties are null relationship is 0, otherwise it is 1.

              2 votes
              Vote
              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)
                You have left! (?) (thinking…)
                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.

                7 votes
                Vote
                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)
                  You have left! (?) (thinking…)
                  0 comments  ·  tools  ·  Flag idea as inappropriate…  ·  Admin →
                • Allow SqlQuery to execute partial property select statement.

                  SqlQuery does not allow you to execute select query that has missing map on your POCO class. There are case that we need to to fill our POCO class with certain selection of property only.

                  1 vote
                  Vote
                  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)
                    You have left! (?) (thinking…)
                    0 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
                  • 3 votes
                    Vote
                    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)
                      You have left! (?) (thinking…)
                      0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                    • Support interfaces as entity and complex types

                      It's unfortunate not to be able to mark interfaces for EF mapping (code first). This will allow to really abstract the implementation. Allows a unique representation of the data in the context of RIA Services (if Ria Services allows also for interface 'mapping'). This won't be very hard to implement since EF is happy when it subclasses... For the benefits: imagine you have only interfaces to declare your model. On the server side, you use EF to get your interfaces 'filled' from DB. on the client side you get those same interfaces filled by RIA services... You can reuse any…

                      759 votes
                      Vote
                      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)
                        You have left! (?) (thinking…)
                        19 comments  ·  Flag idea as inappropriate…  ·  Admin →
                      • Delete orphans support

                        Entity Framework should support automatic deletion of orphan records, the way "all-delete-orphan" works in NHibernate.

                        If I have a one-to-many relationship between Orders and OrderLines, and code inside the Order class calls OrderLines.Remove(orderLine), this should cause the order line to be deleted when I save changes. Currently, EF attempts to set the order line's OrderID to NULL. If the OrderID column is non-nullable, the update fails with a constraint violation error.

                        I found this forum post in which Daniel Simmons from Microsoft says EF doesn't support this: http://social.msdn.microsoft.com/forums/en-us/adodotnetentityframework/thread/CB9C1C4A-DF12-44E4-B00A-417C80BF5453

                        This is an important feature for an ORM, since it's difficult to…

                        641 votes
                        Vote
                        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)
                          You have left! (?) (thinking…)
                          13 comments  ·  runtime  ·  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.

                          7 votes
                          Vote
                          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)
                            You have left! (?) (thinking…)
                            0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                          • Eager loading for properties of derived classes

                            In entity framework there should be a way to eager load (include) navigation properties of a derived class.

                            When in an data model for entity framework has a navigation property it is not posseble to eager load that navigation property besides when using OfType<> or when eager loading the derived type itself by a navigation property.
                            This could be done by using a special syntax of the include path.
                            Since a property of the base class can not have the same name as the derived class, it would also be possible to navigate to the derived class by its name.

                            716 votes
                            Vote
                            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)
                              You have left! (?) (thinking…)
                              19 comments  ·  Flag idea as inappropriate…  ·  Admin →
                            • dynamic discriminator

                              use in the discriminator column the assemblyqualifiedname to be able to store any class that extend the base entity

                              3 votes
                              Vote
                              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)
                                You have left! (?) (thinking…)
                                0 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
                              • Support for compact frameworks

                                support for .net CF 3.5 and 3.7 please...

                                3 votes
                                Vote
                                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)
                                  You have left! (?) (thinking…)
                                  0 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
                                • Support for Linked SQL Servers

                                  Add support for Linked servers.

                                  7 votes
                                  Vote
                                  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)
                                    You have left! (?) (thinking…)
                                    1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                                  • Support for timestamp in model-first

                                    You cannot use optimistic concurrency in model-first mode. This is because the entity designer does not support a timestamp type. Even if you add a timestamp column and update your model, it turns into binary(8) in the generated SQL. Manual changes to set the type to "timestamp" in the EDMX file are overwritten and the property reverts to Binary(8).

                                    As far as I can tell, this makes it impossible to use this feature in model-first mode.

                                    14 votes
                                    Vote
                                    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)
                                      You have left! (?) (thinking…)
                                      0 comments  ·  tools  ·  Flag idea as inappropriate…  ·  Admin →
                                    • 12 votes
                                      Vote
                                      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)
                                        You have left! (?) (thinking…)
                                        0 comments  ·  tools  ·  Flag idea as inappropriate…  ·  Admin →
                                      • Ability to specify NoLock and other query hints

                                        Table lock, update lock ( WITH(UPDLOCK) / FOR UPDATE ).
                                        LockMode something like NHibernate.

                                        Also should support controlling parameter sniffing

                                        http://stackoverflow.com/q/9890699/85196

                                        281 votes
                                        Vote
                                        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)
                                          You have left! (?) (thinking…)
                                          8 comments  ·  runtime  ·  Flag idea as inappropriate…  ·  Admin →
                                        • Visual Studio Database Project integration

                                          Support for updating a Visual Studio Database Project(s) instead of updating the db directly with an ad-hoc file.

                                          Currently 4.0 allows us to generate our database schema from the model but its capabilities are limited and destructive:
                                          unique keys – no support
                                          schema generation – destructive

                                          Database Projects for Visual Studio has already matured and more importantly has the capability of updating schemas without being destructive to the data. It would be nice to see the next designer integrate fully with this product rather than re-invent the wheel. For those of us that manage our databases using Database Projects this…

                                          7 votes
                                          Vote
                                          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)
                                            You have left! (?) (thinking…)
                                            0 comments  ·  tools  ·  Flag idea as inappropriate…  ·  Admin →
                                          • Don't see your idea?

                                          Entity Framework Feature Suggestions

                                          Feedback and Knowledge Base