add type map to support queries with legacy types that don't exist in the data anymore