MAIDR Documentation - v4.4.0
    Preparing search index...
    • Map view-order column positions onto the data table's alphabetical ones.

      DataTableReader sorts its columns alphabetically and offers no way to ask for view order, while getSummaryColumnsInfoAsync is in view order and carries no data. Matching them by fieldId — as Tableau's own snippet does — is the only bridge. fieldName is tried second so a host that omits fieldId degrades to a working read rather than to no columns at all.

      Parameters

      • viewColumns: readonly TableauColumn[]

        Columns in view order.

      • tableColumns: readonly TableauColumn[]

        Columns of a data table page, alphabetically sorted.

      Returns number[]

      One entry per view column: the alphabetical index to read it from, or -1 when the column has no counterpart in the table.