select: support outputting forward index