Skip to main content
Microsoft Idea

Power BI

Completed

Add support for calculated fields that can return tables (user-defined functions)

Vote (4) Share
Scott Senkeresty's profile image

Scott Senkeresty on 02 Jul 2015 22:58:19

Especially for custom calendars it would be awesome to define your own functions for YTD, etc. But more generically being able to define a measure that returns a table/filter would be awesome.

[LargeNationalCustomers] := FILTER(Customers, Customers[Region] = "National" && Customers[NumEmployees] > 100)

[Revenue_LargeNatl] := CALCULATE(SUM(Transactions[Revenue], [LargeNationalCustomers])

The decision to limit calculated fields to just scalars... feels almost arbitrary and counter productive.

Comments (1)
Scott Senkeresty's profile image Profile Picture

Scott Senkeresty on 05 Jul 2020 22:08:07

RE: Add support for calculated fields that can return tables (user-defined functions)

I claim this is not the same thing, since calculated tables are only resolved once during refreshe... and I want something dynamic.