entity framework - accessing foreignkeytables in LINQto EF query -


i have foreign key tables in database(mysql). why these not accessible in linq ef? example have table shippinglocationscontacts, why table not become part of ef model? how can access these tables in linq ef?

i bet shippinglocationscontacts junction table. contains shippinglocationid , contactid (or similar names). ef feature. maps junction tables many many association between, in case, shippinglocations , contacts.

so contact has property shippinglocations , shippinglocation has property contacts.

you don't manipulate table directy. add items collections (like shippinglocation.contacts.add(contact) , ef insert record in junction table.


Comments

Popular posts from this blog

ios - iPhone/iPad different view orientations in different views , and apple approval process -

monitor web browser programmatically in Android? -

c# - Using multiple datasets in RDLC -