Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowGet inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.
Hey all,
Is it possible to add up previous numbers in a column if they are at an earlier date by item code.
For example,
Item Code | date | Quantity | New Column |
a | 01/01/23 | 10 | 10 |
a | 03/01/23 | 15 | 25 |
a | 06/01/23 | 5 | 30 |
a | 11/01/23 | 20 | 50 |
b | 05/01/23 | 30 | 30 |
b | 15/01/23 | 25 | 55 |
Hope this makes sense. Let me know if you need anymore information.
Thanks
Nathan
Solved! Go to Solution.
Hi,
Please check the below picture and the attached pbix file.
It is for creating a new column.
Expected result CC =
SUMX (
WINDOW (
1,
ABS,
0,
REL,
SUMMARIZE ( Data, Data[Item Code], Data[date], Data[Quantity] ),
ORDERBY ( Data[date], ASC ),
KEEP,
PARTITIONBY ( Data[Item Code] )
),
Data[Quantity]
)
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
Hi,
Please check the below picture and the attached pbix file.
It is for creating a new column.
Expected result CC =
SUMX (
WINDOW (
1,
ABS,
0,
REL,
SUMMARIZE ( Data, Data[Item Code], Data[date], Data[Quantity] ),
ORDERBY ( Data[date], ASC ),
KEEP,
PARTITIONBY ( Data[Item Code] )
),
Data[Quantity]
)
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
That Worked!!
Thank you heaps
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
126 | |
113 | |
71 | |
65 | |
46 |