Several fixes, onging work to make new schema work.
Separating base class + specialization code.