- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
CALCULATETABLE( SUMMARIZE( aggregation by def
"Hey, I need some assistance, please. I have the following formula. I also have another dataset, which is a file of shipment allocations by trucks and customers. I want to implement a condition where if a customer doesn't have an order totaling $800 on a specific date, then that order will be added to the next order. In the next order, it will again check if it reaches $800, and this can take into account the data from the previous order if there was one. So, I created a pivot for the original dataset, and now I'm planning to filter the data by customer and date, so I can identify when the condition occurs. Essentially, I want to reduce the number of shipments, so it only happens if the order reaches the threshold of $800. However, it's important to note that if there's an order for less than $800, we wait for accumulation until such an order is formed.
I am currently conducting the check on a specific month in the year 2024
like this ,
customerShipments =
CALCULATETABLE(
SUMMARIZE(
'TABLE1',
'TABLE1'[customer],
'TABLE1'[date],
"Qty", SUM('TABL1'[AMOUNT])
),
'TABL1'[Year] = 2024,
'TABL1'[Month] = 2,
''TABL1'[AMOUNT] > 0
)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Please, I have attached a link to the file, thanks for wanting to help.
https://drive.google.com/file/d/1VjC7gl7L5T4MPWYfwvP55QEYyLIzAgZx/view?usp=sharing
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
HI @benjaminzaidner,
After I test and coding formula on sample file based on your conditions, I find this requirement is a recursive calculation which not able to be achieved in Dax expressions.
You can simply to check if current value is large than the target, but it is hard to use Dax to find the dynamic cumulative start range. (this should base on previous calculations)
If you want to know more about recursion calculation, you can take a look at Greg’s blog:
Previous Value (“Recursion”) in DAX
Regards,
Xiaoxin Sheng
If this post helps, please consider accept as solution to help other members find it more quickly.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @benjaminzaidner ,
Can you please share a pbix or some dummy data that keep the raw data structure with expected results? It should help us clarify your scenario and test to coding formula.
How to Get Your Question Answered Quickly
Regards,
Xiaoxin Sheng
If this post helps, please consider accept as solution to help other members find it more quickly.

Helpful resources
Subject | Author | Posted | |
---|---|---|---|
03-04-2025 01:53 AM | |||
06-22-2021 06:04 AM | |||
03-27-2025 02:14 AM | |||
01-28-2025 03:52 AM | |||
10-07-2021 01:36 AM |
User | Count |
---|---|
12 | |
10 | |
10 | |
9 | |
9 |