refactor the schema representation to use indices instead of names for the primary key columns, in preparation for reuse.  remove some unnecessary code from some internal callback structs.