Forum


HomeHomePremiumPremiumDevelopmentDevelopmentDAL2 compliled module relationshipsDAL2 compliled module relationships
Previous
 
Next
New Post
2/27/2015 6:43 AM
 

Hi,

I'm looking to a way to do many-to-many relationships in DAL2 compiled module.

Table1 Item

Table2 Picture

Table3 ItemPictureMapping

 

Martin

 
New Post
3/1/2015 2:29 PM
 

Martin,

I recently had a forum question similar to what you are asking.  See this More Complex "Client Centric" recomendations.

Possibly creating DAL2 entities for Item and Picture.  In the Item DAL2 entity, you can create a List<Picture> attribute with [IgnoreColumn].  Then in your ItemController you can add code in the Get* methods to populate the Picture list based on another DB call.

If your module code requires complex DB relationships and/or tuning, you may need to use another data layer strategy like Entity Framework or classic DAL.  See my tutorial on Data Access Layer Selection.

 
Previous
 
Next
HomeHomePremiumPremiumDevelopmentDevelopmentDAL2 compliled module relationshipsDAL2 compliled module relationships



Try FREE
30 days money back guaranteed