What's the NHibernate session.Load equivalent in Entity Framework?

Viewed 1375

What's the following NHibernate lazy loading equivalent to Entity Framework?

product.Categories.Add(s.Load<Category>(cat));

I tried this, but it read the Category table from the database:

product.Categories.Add(db.Categories.Find(cat));
3 Answers
Related