def _field_ids(extent_map, field_names):
    """Convert a (field-name, ...) tuple to a (field-id, ...)
    tuple for the given extent map."""
    field_name_id = extent_map['field_name_id']
    return tuple(field_name_id[name] for name in field_names)