LowCodeStacks™
Sign in

What is incremental refresh? Power BI's RangeStart and RangeEnd

What Power BI incremental refresh is, how RangeStart and RangeEnd filter a big table, the query-folding trap, and four ways to prove each refresh is incremental.

Power BIFix a problem6 min read

Checked against Microsoft Learn 5 sources · Updated By · drafted with AI help, checked by a personHow we write guides

What is incremental refresh? It's how Power BI incremental refresh spares a 50-million-row fact table from reloading ten years of history every night: two Power Query parameters called RangeStart and RangeEnd split the table into date partitions, each refresh reloads only the recent ones, and history is left alone. It works on Pro as well as Premium and PPU. The hard part isn't turning it on; it's being sure it's actually incremental.

Top, the rolling window that incremental refresh keeps, with time running left to right. Data older than the archive period drops off. Historical partitions cover the archive period, for example 5 years: stored, rarely refreshed, and old ones merge. Refresh partitions cover the refresh period, for example 3 to 10 days before the refresh date: reloaded on every refresh. The refresh date is in UTC unless you set a time zone. After the refresh period, an optional real-time DirectQuery partition can show the latest data, on Premium, PPU or Embedded only. Bottom, the query-folding trap. When the RangeStart and RangeEnd filter comes right after the source step, it folds to the source as a WHERE clause, so only the refresh period is read. When a step before the filter stops query folding, every row is downloaded and filtered inside Power BI or on the gateway, so the refresh is as slow as before.
Each refresh reloads only the refresh partitions, as long as the date filter folds to the source.

What is incremental refresh?

Incremental refresh is a Power BI setting for the big tables of a semantic model, usually a fact table that keeps growing. The service splits each of those tables into date partitions and refreshes only the most recent ones, so older history isn't reloaded every time. You define the policy in Power BI Desktop, and the service applies it on each refresh once you've published.

How it works, in one paragraph

You add two date/time parameters, RangeStart and RangeEnd, and filter the table with them. In Power BI Desktop they load a small slice. After you publish, the service overrides them. The first refresh creates historical partitions (stored, rarely refreshed) and refresh partitions (reloaded each time). Each later refresh queries only the refresh period. Old partitions merge, and drop off after the archive period. Microsoft calls this a rolling window.

Step 1: Create the RangeStart and RangeEnd parameters

  1. In Power Query, select Manage Parameters and create RangeStart and RangeEnd. The names are case-sensitive, the type is Date/Time, and the values give you a couple of days of data in Desktop. RangeStart is the earliest date and time in the slice, and RangeEnd the latest.
  2. Filter the date column. Include the start, exclude the end, so no row lands in two partitions:
powerquery
Table.SelectRows(Source, each [OrderDate] >= RangeStart and [OrderDate] < RangeEnd)

Integer date keys such as 20261006? Convert the parameters inside the filter:

powerquery
each [OrderDateKey] >= Int32.From(DateTime.ToText(RangeStart, [Format="yyyyMMdd"]))
 and [OrderDateKey] <  Int32.From(DateTime.ToText(RangeEnd,   [Format="yyyyMMdd"]))

Step 2: The policy, in plain words

In Power BI Desktop's Table view, right-click the table in the Data pane and select Incremental refresh. Under Incrementally refresh this table, move the slider to On. If the slider is greyed out, the table's query has no RangeStart/RangeEnd filter yet.

SettingMeansTypical
Archive data starting … before refresh dateHow much history to keep5 years
Incrementally refresh data starting … before refresh dateHow much recent data to reload every time3–10 days: enough to catch late changes
Only refresh complete daysSkip today's partial dataOn for daily totals
Detect data changesReload a period only if a "last updated" column changed. Use a different column from the one you partition onWhen the source has an audit column
Get the latest data in real time with DirectQueryAdds a live partition after the refresh periodPremium, PPU or Embedded only

Time zone: "today" is in UTC unless you set a time zone under the model's Refresh settings.

Step 3: Watch out for query folding

The filter has to reach the source, as a WHERE clause or similar. If a step before the filter stops query folding, the import may still download every row and filter it inside Power BI or on the gateway. Then the refresh is as slow as before, and can run out of resources.

  • Put the RangeStart/RangeEnd filter right after the source step.
  • If the policy dialog shows a folding warning, check with Power Query Query Diagnostics, or with the source's own trace.
  • A hand-written SQL query can work too, if you put the parameters inside the SQL.

Step 4: Publish once, then refresh

  • Run the first refresh manually and watch it. It's the long one: it creates partitions and loads all the history.
  • On Premium, turn on the large semantic model format before that first refresh if the model may grow beyond 1 GB.
  • After publishing, you can't download the PBIX back from the service.
  • Republishing from Desktop replaces the model's partitions and data. On Premium, deploy later changes as metadata only, for example through the XMLA endpoint with tools such as ALM Toolkit.

Step 5: Prove each refresh is incremental

Partitions existing only shows the policy was applied. It doesn't prove the last refresh loaded only the recent window. Check one of these:

  1. Duration: later scheduled refreshes should take a fraction of the first. Compare them in the refresh history.
  2. The source's logs: the queries Power BI sends should carry a date filter covering only the refresh period. Use SQL Server's query store or a trace, or the source's equivalent.
  3. Enhanced refresh details (Premium, PPU or Embedded): GET …/refreshes/{requestId} shows what each refresh processed.
  4. Partitions in SQL Server Management Studio (Premium, with the XMLA endpoint on): connect to the workspace and look at the table's partitions after a refresh.

Limits to remember

  • Refresh still has the 2-hour (Pro) and 5-hour (Premium) limits. XMLA refreshes on Premium don't.
  • Every table with a policy must use the same RangeStart and RangeEnd parameters.
  • All partitions must come from one data source.

If a refresh fails outright rather than running slowly, work through our Power BI refresh failures checklist.

Sources

Add LowCodeStacks as a preferred source on Google

Did this fix it?

Comments

No comments yet. Share what worked for you.

Sign in to comment. Comments show under a display name you choose, never your email.