Search for existing suggestions

Ability to map any serializable object to XML, JSON or binary columns

For example a database table could have a [Settings] column of type xml. And a mapped entity type could have a property [Settings] of some serializable type. Then you will be able to read and write data into and from this [Settings] column with EF. Like this:

var user = db.Users.First(x => x.ID == 1);
if (user.Settings == null)
{
user = new Settings();
}
user.Settings.ProductsPerPage = 20;
db.SaveChanges();

37 votes
Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)

We’ll send you updates on this idea

Konstantin Tarkus shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

3 comments

Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)
Submitting...
  • Eniola Benjamin commented  ·   ·  Flag as inappropriate

    Hibernate has a similar feature where you can have HashMaps of values and have them stored in one column rather than as Entities/Tables.

    The same thing will apply for Scalar complex objects that we want to serialize as XML rather than back with a column mapped to each property of the Complex object.

Feedback and Knowledge Base