Forum Discussion
Benchmark line in combo visual
Is there an easy way to add a benchmark line in a combo visual?
Right now, an 85% benchmark is a bar (comparing against the bar total scores). The user wants to change it to a line.
My second thought was to use the right total Invoiced YTD, gettinging the Max "total invoiced", then do 85% of the max, and apply it to each company. However, I was having difficulty building a measure with a constant value across all companies.
FIrst, I have to figure out what the max (total invoiced YTD) across companies, which I can do, and put in a card visual (code 1 below). However, when I try to add that measure to the line axis, I get this error, because it seems PowerBI is trying to split the data back across companies:
Code1:
maxInvoicedItemsYTD =
VAR yearBeginning =
DATE ( YEAR ( MIN ( 'Date'[Date] ) ), 1, 1 )
VAR periodEnd =
MAX ( 'Date'[Date] )
VAR InvoiceTotal =
MAXX(
SUMMARIZECOLUMNS(
Vendors[No],
FILTER(
ALL ( PurchaseInvoiceLine ),
PurchaseInvoiceLine[PostingDate] >= yearBeginning
&&PurchaseInvoiceLine[PostingDate] <= periodEnd
),
FILTER(Vendors,Vendors[WTE Scorecard]=1),
"TotalInvoiced",
COALESCE ( SUM ( 'PurchaseInvoiceLine'[Amount] ), 0 )
),[TotalInvoiced]
)
return InvoiceTotal
- Anonymous2 years ago
Seems like this link answered my question 😞
https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-analytics-pane
1 Reply
- AnonymousNot applicable
Seems like this link answered my question 😞
https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-analytics-pane