Manage Tree With Entity Framework – The basic
One of the most obvious problem showed in previous post is the need to issue a single Select for each node to rebuild the tree, but the good thing is that there are a lot of solutions over there to solve this problem. One of the most interesting [...]
Continue reading about Manage trees with entity framework part II
Quite often you need to store in database Hierarchical structure that are logically represented by a tree. There are a lot of techniques around there, but one of the most common is using a simple foreign key that refers to the same table, as in the following example
If you map this table with entity [...]
I have a local copy of my blog in my machine, just to test if I need to do some modification to the skin or to some pages of the blog, everything is always gone ok, just installing php, mysql and the blog works great.
Today I need to reinstall php and mysql because my machine [...]
In previous post I left to the reader the task to build a LoadByKey extension method to make it easy loading entities by key in project with entity framework, I think that is quite interesting to spent a little bit on in. First of all I suggest you to read this post about metadata and [...]
Continue reading about Extension method to add LoadByKey to EntityFrameworks context
Suppose you generate an Entity Framework model on standard northwind database, you have a customer id and you want to generate an order for that customer. A possible solution is
using (ModelTestBase context = new ModelTestBase())
{
Orders order = new Orders();
order.Freight = 1.0M;
order.RequiredDate = order.OrderDate = DateTime.Now;
[...]
Continue reading about Entity Framework relations and entityKey




