views:

325

answers:

2

I've noticed that if i have an Pk/FK association, the FK ID is removed from the entity in the designer. How do I join query statements?

Basically I'm looking for some good Linq to Entity video tutorials (sorry, I'm an audio/visual learner)

A: 

i found my answer on this post

EdenMachine
+1  A: 

Say you have a 'review' item, and it is related to a 'product' you would do something like this:

review.productsReference.Value = db.products.First(p => p.product_id == 2);

Setting the reference.Value equal to the object itself.

http://naspinski.net/post/Getting-started-with-Linq-To-Entities.aspx

naspinski