I have this base abstract class which implements repository pattern
public abstract class Repository<T> : IRepository<T> where T : class
{
private ObjectSet<T> _entitySet;
private ObjectContext _dataContext;
public Repository(ObjectContext context)
{
_dataContext = context;
_entitySet = _dataContext.CreateObjectSet<T>();
}
public T FindByID(int id)
{
//??????
}
}
Now I need to know primary key column (corresponding property) to implement FyndByID method.
Suggest that priamry key is not composite and it's datatype is int