nHibernate multiple classes pointing to same table?
Posted
by Amitabh
on Stack Overflow
See other posts from Stack Overflow
or by Amitabh
Published on 2010-03-12T19:08:15Z
Indexed on
2010/03/13
2:37 UTC
Read the original article
Hit count: 365
Is it a good idea to create a lighter version of an Entity in some cases just for performance reason pointing to same table but with fewer columns mapped. E.g If I have a Contact Table which has 50 Columns and in few of the related entities I might be interested in FirstName and LastName property is it a good idea to create a lightweight version of Contact table. E.g.
public class LightContact
{
public int Id {get; set;}
public string FirstName {get; set;}
public string LastName {get; set;}
}
Also is it possible to map multiple classes to same table?
© Stack Overflow or respective owner