# Tableau Sets to DAX: Converting Fixed, Dynamic, and Combined Sets to Power BI

> Power BI has no set object. How fixed sets, condition sets, Top N sets and set actions convert to DAX using IN, TOPN, RANKX, UNION and calculated columns.

- Canonical: https://getantares.io/tableau-sets-to-dax-measures/
- Published: 2026-02-18
- Updated: 2026-07-28

---

Power BI has no object called a set. A Tableau set is two things at once: a stored list of members, and an IN/OUT field you can drop on a shelf to split the view into members and everything else. In DAX those two halves separate. Membership becomes a filter expression, and the IN/OUT field becomes either a calculated column, when membership is fixed, or a measure, when it has to be recomputed as the data changes.

## Set type to DAX conversion table

| Tableau | DAX equivalent | Approach |
| --- | --- | --- |
| Fixed set, one dimension | `Product[Color] IN { "Red", "Blue" }` | Table constructor with the `IN` operator |
| Fixed set, several dimensions | Calculated column combining the columns | Only fixed sets can span dimensions |
| Condition set | `FILTER(VALUES(Product[Product]), [Sales] > 100000)` | Evaluated at query time |
| Top N set | `TOPN(5, VALUES(Product[Product]), [Sales])` | Returns ties, so possibly more than N |
| Top N, exactly N rows | `RANKX(ALLSELECTED(Product[Product]), [Sales]) <= 5` | Ranking instead of a table |
| IN/OUT on a shelf | Calculated column, or a measure returning "In" or "Out" | A visual cannot group rows by a measure |
| All Members in Both Sets | `UNION` | Combined sets |
| Shared Members in Both Sets | `INTERSECT` | Combined sets |
| Except Shared Members | `EXCEPT` | Order of arguments matters |
| Set action | Cross-filtering, bookmarks, or a disconnected table | No stored, user-updatable set exists |

## Fixed sets are a column, dynamic sets are a measure

Tableau's own distinction is the one to convert against: the members of a fixed set do not change when the data changes, while a [dynamic set](https://help.tableau.com/current/pro/desktop/en-us/sortgroup_sets_create.htm) does, and a dynamic set can only be based on a single dimension. A fixed set is therefore a stored list, and a calculated column carrying a flag is the honest translation. It costs a little memory, it can be sliced, filtered and put on an axis, and it behaves exactly like the Tableau original.

A dynamic set cannot become a column, because its membership depends on aggregates that only exist at query time. It becomes a measure or a calculated table. That creates the one structural gotcha in this conversion: Power BI cannot group the rows of a visual by a measure. If the Tableau view puts IN/OUT on rows and users expect two bars, you either accept a calculated column with a condition built only from stored values, or you add a two-row table holding "In" and "Out" and write a measure that responds to which row is in context.

## Condition sets and the filter context they run in

A condition set is a rule such as "products whose sales exceed 100,000". In DAX that is a `FILTER` over the values of the column, wrapped in `CALCULATE` or `CALCULATETABLE` when you need it as a filter argument. The question the Tableau formula never had to answer is which context the rule is evaluated in.

Use `VALUES` or `ALLSELECTED` when the set should respect the user's slicers, so a product qualifies against sales in the selected period. Use `ALL` when membership is meant to be absolute regardless of what is filtered. Both are defensible, they produce different member lists, and the difference is invisible until somebody applies a slicer. Decide it deliberately during conversion rather than discovering it in testing.

## Top N sets

[TOPN](https://learn.microsoft.com/en-us/dax/topn-function-dax) is the direct equivalent of Tableau's Top tab, with one documented behaviour worth knowing: if values tie at the Nth row, every tied row is returned, so the function can return more than N rows. Tableau's Top N set has the same intent but not the same tie handling, so a "top 5" that quietly becomes seven rows after migration is a conversion artefact, not a data problem.

When exactly N rows matter, rank instead of taking a top slice: compare `RANKX` against the threshold and treat everything above it as the "Others" bucket. That also gives you the Top N plus Others pattern in one expression, which in Tableau usually needs a set and a calculated field working together.

## Set actions have no equivalent, and that is the expensive part

[Set actions](https://help.tableau.com/current/pro/desktop/en-us/actions_sets.htm) update the contents of a stored set from what the user selects in a viz, which is what makes proportional brushing, asymmetric drill-down and self-adjusting colour scales possible. Power BI has no stored set for a user to write into, so each of these is rebuilt from different parts: cross-filtering between visuals, drillthrough, bookmarks, or a disconnected table whose selection is read back with `SELECTEDVALUE`.

Those rebuilds are design work, not translation, and they are the reason a workbook with a handful of set actions can cost more than one with a hundred plain charts. Price them separately when scoping.

## What Antares does with sets

Sets are reported as manual work rather than auto-converted, alongside LOD expressions and table calculations. What the Analyzer contributes is the distinction that drives the estimate: a fixed set that becomes a calculated column is minutes of work, while a set action wired into a dashboard's interactions is a redesign. Both look like one line in a raw feature count.

Where a mapping is genuinely ambiguous, it is flagged rather than guessed, because a set whose membership silently shifted is the kind of error that surfaces only when a user asks why a total moved. [Run the free Analyzer](https://try.getantares.io) to get the breakdown for your own workbooks.

Related reading: [LOD expressions to DAX](/tableau-lod-expressions-to-dax/), [table calculations to DAX](/tableau-table-calculations-to-dax/) and [groups and hierarchies](/tableau-groups-to-power-bi/). Primary sources: Tableau's [Top N sets guide](https://help.tableau.com/current/pro/desktop/en-us/sortgroup_sets_topn.htm) and Microsoft's references for the [DAX IN operator](https://learn.microsoft.com/en-us/dax/dax-operator-reference), [CALCULATETABLE](https://learn.microsoft.com/en-us/dax/calculatetable-function-dax) and [UNION](https://learn.microsoft.com/en-us/dax/union-function-dax).

## Related resources

- [Tableau to Power BI Migration Guide](/tableau-to-power-bi-migration/)
- [LOD Expressions to DAX](/tableau-lod-expressions-to-dax/)
- [Table Calculations to DAX](/tableau-table-calculations-to-dax/)
- [Groups and Hierarchies to Power BI](/tableau-groups-to-power-bi/)

## FAQ

### What is the Power BI equivalent of a Tableau set?

There is no set object. A fixed set becomes a calculated column carrying a flag, or an IN test such as Product[Color] IN { "Red", "Blue" }. A dynamic set becomes a measure or a calculated table, because its membership depends on aggregates that only exist at query time.

### How do you convert a Tableau Top N set to DAX?

TOPN over the values of the column, ordered by the measure, is the direct equivalent. Note that TOPN returns every row tied at the Nth position, so it can return more than N rows. When exactly N rows are required, compare RANKX against the threshold instead.

### Can Power BI show IN and OUT like a Tableau set?

Only through a column. A visual cannot group its rows by a measure, so an IN/OUT axis needs either a calculated column, when the condition uses stored values, or a two-row helper table holding In and Out with a measure that responds to the row in context.

### What replaces Tableau set actions in Power BI?

Nothing directly, because Power BI has no stored set that a user selection can write into. Proportional brushing, asymmetric drill-down and self-adjusting colour scales are rebuilt from cross-filtering, drillthrough, bookmarks, or a disconnected table read back with SELECTEDVALUE. Scope these as design work.
