Forum Discussion
Distinct Net Value From Deliveries
I am pulling a report from my ERP that lists deliveries shipped at the item level but populates the total net value shipped for delivery on each item line (repeating the total net value for the delivery on each item line). I cannot remove the duplicate deliveries from my data since I am using the item level info on other reports.
I want the net value for each delivery shipped on my report. Basicaly I want a formula that removes the duplicate delivery numbers and gives me the net value. I wrote a formula that I thought would work but it did not.
| Delivery | Plant | Act. Gds Mvmnt Date | Material | Net Value |
| 88033289 | D796 | 3/13/2024 | 22852BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 22851BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 26744BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 26743BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 26344BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 24285BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 42614BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 42624BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 42634BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 42638BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 42630BIO | 13,828.17 |
| 88033289 | D796 | 3/13/2024 | 42650BIO | 13,828.17 |
| 88034684 | D796 | 3/13/2024 | 42630BIO | 8,926.55 |
| 88034684 | D796 | 3/13/2024 | 42656BIO | 8,926.55 |
| 88034684 | D796 | 3/13/2024 | 25766BIO | 8,926.55 |
| 88034684 | D796 | 3/13/2024 | 52368BIO | 8,926.55 |
| 88034684 | D796 | 3/13/2024 | 25767BIO | 8,926.55 |
| 88034684 | D796 | 3/13/2024 | 52366BIO | 8,926.55 |
| 88034684 | D796 | 3/13/2024 | 25768BIO | 8,926.55 |
| 88034684 | D796 | 3/13/2024 | 52728BIO | 8,926.55 |
Net Val = SUMX(FILTER(SUMMARIZE('Delivery Tracking',[Delivery],[Act. Gds Mvmnt Date],[Net Value]),FORMAT([Act. Gds Mvmnt Date],"yyyymm")=FORMAT(TODAY(),"yyyymm")),[Net Value])FORMAT([Act. Gds Mvmnt Date],"yyyymm")=FORMAT(TODAY(),"yyyymm")We are comparing the YearMonth of your data against the YearMonth of the "current" month, ie today's month.
11 Replies
- lbendlin
Super User
you were close
Net Val = SUMX(SUMMARIZE('Delivery Tracking',[Delivery],[Net Value]),[Net Value]) - GMadd
Helper I
Thanks that worked perfectly. Now I need to show only the current months net value. How to I add that to the measure you wrote above?
Thanks again!!
- lbendlin
Super User
Please provide sample data that fully covers your issue.
Please show the expected outcome based on the sample data you provided.
- GMadd
Helper I
I want to use the same measure you created but I want to limit the total to just the current month. My data table has two years worth of shipping data and currently the measure is giving me the total for all deliveries in my table. I do not want to use a filter on my visual for this.
Sample table below. Since the current month year is March 2024 the total should be $355,470.06 Ignoring any other months.
Delivery Plant Act. Gds Mvmnt Date Material Net Value 88028342 D796 2/28/2024 21001STM $44,497.76 88029678 D796 2/28/2024 50024ACL $16,874.60 88029678 D796 2/28/2024 10020ACL $16,874.60 88031087 D796 2/29/2024 43128CLX $374.48 88031087 D796 2/29/2024 42432CLX $374.48 88031087 D796 2/29/2024 44240CLX $374.48 88031086 D796 2/29/2024 32636CLX $381.11 88031086 D796 2/29/2024 24205CLX $381.11 88031085 D796 2/29/2024 36020CLX $483.40 88031077 D796 2/29/2024 42432CLX $278.62 88031077 D796 2/29/2024 36020CLX $278.62 88031077 D796 2/29/2024 24205CLX $278.62 88027366 D796 3/1/2024 75030CSP $33,398.76 88027366 D796 3/1/2024 23002CSP $33,398.76 88027366 D796 3/1/2024 36006CLX $33,398.76 88028943 D796 3/1/2024 26342BIO $131,246.24 88028943 D796 3/1/2024 23733BIO $131,246.24 88028943 D796 3/1/2024 23762BIO $131,246.24 88028943 D796 3/1/2024 26344BIO $131,246.24 88027157 D796 3/1/2024 23758BIO $57,174.68 88027157 D796 3/1/2024 23756BIO $57,174.68 88031155 D796 3/4/2024 17465STM $127,135.78 88031143 D796 3/4/2024 18030STM $6,514.60 - lbendlin
Super User
Net Val = SUMX(FILTER(SUMMARIZE('Delivery Tracking',[Delivery],[Act. Gds Mvmnt Date],[Net Value]),FORMAT([Act. Gds Mvmnt Date],"yyyymm")=FORMAT(TODAY(),"yyyymm")),[Net Value])- GMadd
Helper I
this is working but can you explain how it is only selecting the current month year? I would like to get a better understanding.
Thanks again
- GMadd
Helper I
Thank you for your quick response. This worked perfectly.