Skip to content

feat(power-bi)!: support incremental refresh on storage Costs table - #2353

Open
Michael Flanakin (flanakin) wants to merge 8 commits into
devfrom
flanakin/1799-incremental-refresh
Open

Michael Flanakin (flanakin) wants to merge 8 commits into
devfrom
flanakin/1799-incremental-refresh

Conversation

@flanakin

@flanakin Michael Flanakin (flanakin) commented Oct 16, 2026 •

Copy link
Copy Markdown
Collaborator

🛠️ Description

🤖 [AI] Lets users turn on Power BI incremental refresh for the storage reports' Costs table. Today the incremental refresh dialog can't detect a usable column, because x_IncrementalRefreshDate is stored as text and filtered inside a helper function.

  • Design: ftk_Storage now types x_IncrementalRefreshDate as Date/Time (midnight of the charge date) instead of text, and the storage Costs query ends with a Table.SelectRows on RangeStart/RangeEnd (>= start, < end) so the incremental refresh dialog can detect the filter (Power BI storage reports: incremental refresh isn't detectable out of the box #2314, discussion Incremental refresh CostSummary.storage #1799).
  • ⚠️ Breaking change: x_IncrementalRefreshDate changes from text to Date/Time in all storage tables (Costs, Prices, ReservationDetails/Transactions/Recommendations). Custom filters, measures, or visuals that treat it as text or a number need updating. No new column.
  • Filter behavior: When RangeStart/RangeEnd are null the filter passes every row; when set it matches the ftk_Storage row filter (whole days, same null handling).
  • Scope: Incremental refresh is set up for Costs only. Other tables only get the type change.
  • Untested in Power BI Desktop. Tester should check:
    1. Params empty: Costs row count and totals match dev.
    2. Set RangeStart/RangeEnd to a month: Costs only has that month; x_IncrementalRefreshDate shows Date/Time.
    3. Right-click Costs > Incremental refresh: slider is enabled; apply a policy, publish, refresh in the service; no duplicate or missing days across partitions.

Milestone: v16 (breaking change, and the Desktop/service test didn't happen before v15).

Fixes #2314

📋 Checklist

🔬 How did you test this change?

  • 🤏 Lint tests
  • 🤞 PS -WhatIf / az validate
  • 👍 Manually deployed + verified
  • 💪 Unit tests
  • 🙌 Integration tests

📦 Deploy to test?

  • Hubs + ADX (managed)
  • Hubs + Fabric (manual) — URI:
  • Hubs (manual)
  • Hubs (no data)
  • Workbooks
  • Alerts

🙋‍♀️ Do any of the following that apply?

  • 🚨 This is a breaking change.
  • 🤏 The change is less than 20 lines of code.

📑 Did you update docs/changelog.md?

  • ✅ Updated changelog (required for dev PRs)
  • ➡️ Will add log in a future PR (feature branch PRs only)
  • ❎ Log not needed (small/internal change)

📖 Did you update documentation?

  • ✅ Public docs in docs (required for dev)
  • ✅ Public docs in docs-mslearn (required for dev)
  • ✅ Internal dev docs in docs-wiki (required for dev)
  • ✅ Internal dev docs in src (required for dev)
  • ➡️ Will add docs in a future PR (feature branch PRs only)
  • ❎ Docs not needed (small/internal change)

🤖 Generated with Claude Code

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The logic looks right. x_IncrementalRefreshDateTime converts the OLE serial correctly, and the filter mirrors ftk_Storage, so nothing changes when RangeStart/RangeEnd are empty.

  1. As the description says, this hasn't been tested in Desktop or the service, and no CI job builds the TMDL. Can someone run the three test steps before merge? If not for v15, v16 sounds right.
  2. Rows with a null x_IncrementalRefreshDateTime pass the filter in every partition. With an incremental refresh policy, such rows would be loaded once per partition and inflate costs. Consider dropping them when the range is set, or document it.
  3. Nit (setup.md): "If you need to configure incremental refresh, consider using FinOps hubs…" now sits right after the new incremental refresh link. Maybe "For larger datasets, consider FinOps hubs…".

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Points 2 and 3 from my earlier review are addressed in 502853a (null-date rows are documented, and the setup.md wording is clarified). Point 1 is still open: nobody has run the Power BI Desktop and service test yet, and I haven't either. Following the rule in the description ("If testing can't happen in time, move this to v16"), I suggest moving this to v16 unless someone can run the three test steps before the v15 release.

Comment thread docs-mslearn/toolkit/changelog.md Outdated
@flanakin Michael Flanakin (flanakin) modified the milestones: v15, v16 Oct 19, 2026
@flanakin Michael Flanakin (flanakin) changed the title feat(power-bi): support incremental refresh on storage Costs table feat(power-bi)!: support incremental refresh on storage Costs table Oct 19, 2026
@microsoft-github-policy-service microsoft-github-policy-service Bot added the Breaking change 🚨 Change that breaks previous deployments and requires a new major version label Oct 19, 2026
@flanakin

Copy link
Copy Markdown
Collaborator Author

🤖 [AI] Roland Krummenacher (@RolandKrummenacher) Thanks. Point 1: moved to v16, since the Desktop/service test didn't happen before v15. While at it, dropped the new x_IncrementalRefreshDateTime column and changed the existing x_IncrementalRefreshDate from text to Date/Time in place (ftk_Storage and all storage tables). The final Table.SelectRows on RangeStart/RangeEnd stays so the incremental refresh dialog detects it. Changelog moved to Unreleased and marked as a breaking change; setup.md and the data dictionary updated. Points 2 and 3 were already addressed. The three Desktop/service test steps still need to run before merge.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-reviewed 0a2d198. Changing x_IncrementalRefreshDate to Date/Time is cleaner than a second column. The type is consistent across Costs, Prices, ReservationDetails, ReservationRecommendations, and ReservationTransactions. The ftk_Storage filter and the Costs filter use the same comparison, and the changelog entry moved to Unreleased with the breaking change marker, which resolves my changelog thread.

Approving. Please still run the three test steps in Power BI Desktop and the service before v16 ships.

Comment thread src/power-bi/storage/Shared.Dataset/definition/expressions.tmdl
Comment thread src/power-bi/storage/Shared.Dataset/definition/tables/Costs.tmdl
@flanakin
Michael Flanakin (flanakin) force-pushed the flanakin/1799-incremental-refresh branch from 8966ec6 to 7fd370d Compare October 23, 2026 07:11

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-reviewed 2e2f059 after the rebase onto dev. The net diff matches what I approved at 0a2d198 except for ms.date. Still approved.

Add a Date/Time x_IncrementalRefreshDateTime column and a final
RangeStart/RangeEnd filter step to the storage Costs query so the Power BI
incremental refresh dialog can detect it. The filter passes all rows when
the parameters are empty and mirrors the ftk_Storage row filter otherwise.
Document setup steps and the new column.

Fixes #2314

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ws in incremental refresh

Co-Authored-By: RolandKrummenacher <RolandKrummenacher@users.noreply.github.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
… of adding a new column

Move to v16 as a breaking change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@flanakin
Michael Flanakin (flanakin) force-pushed the flanakin/1799-incremental-refresh branch from 2e2f059 to 56033e9 Compare October 26, 2026 09:05

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-approving after the rebase onto dev. The range-diff against my last reviewed head (2e2f059) shows the commits are unchanged apart from ms.date bot commits. The red Pester check is the broken finops-toolkit-ecosystem.md link in roadmap.md on dev, which #2341 fixes. This PR didn't cause it.

Comment thread src/power-bi/storage/Shared.Dataset/definition/tables/Costs.tmdl

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Breaking change 🚨 Change that breaks previous deployments and requires a new major version Needs: Review 👀 PR that is ready to be reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Power BI storage reports: incremental refresh isn't detectable out of the box

3 participants