Monthly Archives: September 2014

//September
22 09, 2014

Entity Framework many-to-many code first

By | September 22nd, 2014|Entwicklung|0 Comments

Here is an example of how to model a many-to-many relation with Entity Framework using code first. UseCase: one user can have multiple roles and one role can have muliple users. This results in a many-to-many relationship between user and role. What I like to model looks like this: many-to-many relation between user and [...]

22 09, 2014

Entity Framework one-to-many code first

By | September 22nd, 2014|Entwicklung|1 Comment

Here is an example of how to model a one-to-many relation with Entity Framework using code first. UseCase: One user can write multiple Blogs, but a Blog is written by one user. This results in a one-to-many relationship between user and blog. What I like to model looks like this: one-to-many relation between user [...]

22 09, 2014

Entity Framework one-to-many database first

By | September 22nd, 2014|Entwicklung|0 Comments

Here is an example of how to model a one-to-many relation with Entity Framework using database first. UseCase: One user can write multiple Blogs, but a Blog is written by one user. This results in a one-to-many relationship between user and blog. What I like to model looks like this: one-to-many relation between user [...]

22 09, 2014

Entity Framework many-to-many database first

By | September 22nd, 2014|Entwicklung|1 Comment

Here is an example of how to model a many-to-many relation with Entity Framework using database first. UseCase: one user can have multiple roles and one role can have muliple users. This results in a many-to-many relationship between user and role. What I like to model looks like this: many-to-many relation between user and [...]