How to create new table in dax only with new value comparing date to date if existe in previous date
I'm trying to create a new table in Power BI (not in Power Query) that will contain only those rows that are not present in the main table by comparing the list of values for each date from the main table in chronological order. I will add that the main table contains an incremental data set with an increasingly recent date, so it is a table containing an increasingly fresh state of the same data. I want to show what's new in each snapshot that wasn't in the previous drop. I tried to use PARALLELPERIOD, but my date is not cyclic so I made an index on the date to be able to compare them, but PARALLELPERIOD only uses the date format. What's more, more fresh drops will still be added, unfortunately at irregular intervals. Below, on the left, an example of the main table and on the right, what I want to get.
I have some questions. According to what you said, fgh in 2022/10/29 so it cannot appear in 2021/11/1. Why it still appears?
I have created a simple sample, please refer to it to see if it helps you.
Measure 2 =
VAR _date = MAX('Table'[date])
VAR _table1 = CALCULATETABLE(VALUES('Table'[name2]),'Table'[date]=_date)
VAR _date2 = CALCULATE(MAX('Table'[date]),FILTER(ALL('Table'),'Table'[date]<MAX('Table'[date])))
VAR _table2 = CALCULATETABLE(VALUES('Table'[name2]),FILTER(ALL('Table'),'Table'[date]=_date2))
VAR _table = INTERSECT(_table1,_table2)
VAR _result =
NOT MAX('Table'[name2]) IN _table,MAX('Table'[name2])
Hello, thank You very much. It's working as i want it.
According to your question "I have some questions. According to what you said, fgh in 2022/10/29 so it cannot appear in 2021/11/1. Why it still appears?" - it was my mistake in sample.
But i have one problem with that solution. It's killing my Power BI. I'm receivig masaage that there is not enough memory to finish that operation. I was able to implement it but now i can't do anytging in my Power BI. I alredy try it with only Power BI on. But it does't change anything, even i have computer with i7, 32 GB 😞
Is it posibble to optimize some how these solution?