I have an "Investment" entity that is derived from "BaseEntity". If I create and add a new "Investment" like so:
investment = new Investment();
investment.Name = "Investment 01";
_context.BaseEntities.AddObject(entity);
and query the count (before saving changes)
_context.BaseEntities.OfType<Investment>().Count();
it returns zero. The same line returns 1 after _context.SaveChanges();
What am I doing wrong?