Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I hope someone can help. I have table of invoice records. I want to create measurement that will calculate the total Shipping Amount for the most recent invoice. The below measurement works as expect however the calculation only applies if the most recent invoice date is included in the report filter. For example, my current results shows the following. How do I get the $1000 value to appear on both records?
Customer Invoice Date ShippingCharge_Current
XYZ 11/11/21 blank
11/12/21 $1000
ShippingCharge_Current =
Var LastInvoiceDate = CALCULATE(MAX('Invoice'[InvoiceDate]),ALLEXCEPT(‘Invoice’ )[Customer]),ALL(Calendar), ‘Invoice'[Shipping]<0
Var LastInvoiceNum= CALCULATE(Max('Invoice'[Invoice Number]),AllExcept('Invoice',[Customer]),ALL(Calendar),'Invoice'[InvoiceDate] =LastInvoice)
Return CALCULATE('Invoice'[Shipping_Measurement],ALL(Calendar),AllExcept('Invoice',[Customer]),FILTER('Invoice','Invoice'[InvoiceNumber]= LastInvoiceNum))
The suggestion did not work. I need the current shipping charge to appear on all invoice records.
How do I incorporate this in my current code?
Can you provide more direction. I need a single value measurement. Not a table.
Thanks
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
10 | |
9 | |
8 | |
8 | |
8 |
User | Count |
---|---|
13 | |
12 | |
11 | |
10 | |
8 |