Forum Discussion
Price variation
Hello!
I need to create for my colleagues a table with the different prices that a product has had (for example, if in May I have sold it 20 times at the same price I only want to see a price), and the variations that this new price has with respect to the previous one, which I am only getting when I do not filter or sort by date.
I created this matrix
The variation measure is calculated with price measures that are a lookupvalue of the price value for the following date measurements
1 Reply
- amitchandakSuper User
Syndicate_Admin
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.usually we can create a new column
new column =
var _max = maxx(filter(Table, [Item] = earlier([Item]) && [Date] < earlier([Date]) ), [Date])
return
maxx(filter(Table, [Item] = earlier([Item]) && [Date] =_max), [price])
Earlier, I should have known Earlier: https://youtu.be/CVW6YwvHHi8