Forum Discussion
Wierd behaviour with Powerbi and datediff
Hi,
I have a report with the following measure
Anonymous When using measures, references to columns have to include an aggregation function like SUM, MIN, MAX, etc. This is a big difference from calculated columns. Calculated columns have row context and so do not need aggregation functions to reference other columns because the default is to get the value in the column for the same row.
4 Replies
- AnonymousNot applicable
Both are imports - one is from a odbc connection to a database.. the other is from an excel table.
In the end I made it a calculated column.. strange behaviour though!
- Greg_Deckler
Community Champion
Anonymous When using measures, references to columns have to include an aggregation function like SUM, MIN, MAX, etc. This is a big difference from calculated columns. Calculated columns have row context and so do not need aggregation functions to reference other columns because the default is to get the value in the column for the same row.
- AnonymousNot applicable
My error - was initially a calculated column.. been a long day
- Greg_Deckler
Community Champion
Anonymous So is this via a Live connection to the dataset or Direct query for Power BI datasets or are they both import models? Also, if this is really a measure and not a calculated column, you should need an aggregation function around the column reference (INVOICE[INVOICE_DATE])