The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi everyone,
This is my first post, as I've used this form many times to help me out, but I cannot find a fitting solution this time.
I have a visual in which I'd like to display the unique number of products that are checked per month and the running total (of unique products that are checked) for that year.
The number of unique products is calculated with a simple measure:
Solved! Go to Solution.
In the meantime I've found a solution offline that seems to work and which I'm happy to share.
As a first step I've added a calculated column to my table;
FirstOccurrence =
VAR CurrentYear = YEAR('Voorraad vs Scanning'[Datum])
VAR CurrentValue = 'Voorraad vs Scanning'[Artikel]
RETURN
IF(
MINX(
FILTER(
'Voorraad vs Scanning',
'Voorraad vs Scanning'[Artikel] = CurrentValue &&
YEAR('Voorraad vs Scanning'[Datum]) = CurrentYear
),
'Voorraad vs Scanning'[Datum]
) = 'Voorraad vs Scanning'[Datum],
CurrentValue,
BLANK()
)
As a final step I've counted the number of non-blank occurence of this "FirstOccurrence".
In the meantime I've found a solution offline that seems to work and which I'm happy to share.
As a first step I've added a calculated column to my table;
FirstOccurrence =
VAR CurrentYear = YEAR('Voorraad vs Scanning'[Datum])
VAR CurrentValue = 'Voorraad vs Scanning'[Artikel]
RETURN
IF(
MINX(
FILTER(
'Voorraad vs Scanning',
'Voorraad vs Scanning'[Artikel] = CurrentValue &&
YEAR('Voorraad vs Scanning'[Datum]) = CurrentYear
),
'Voorraad vs Scanning'[Datum]
) = 'Voorraad vs Scanning'[Datum],
CurrentValue,
BLANK()
)
As a final step I've counted the number of non-blank occurence of this "FirstOccurrence".
Hello All,
Link has been updated. This time it should work.
Hi some_bih,
I've tried to attach the pbix for reference (I hope it worked). I've also had a look at COUNTAX, but couldn't get that to provide the desired outcome. So....if anyone has any additional suggestions, I'd love to hear them.
Hi @D_Brouwers your file is not visible.
Proud to be a Super User!
Hi @D_Brouwers
usually, SUMX summing some numberical column, like quantity, price... check link for official documentation
your model is not available, so maybe you need COUNTAX
Proud to be a Super User!
User | Count |
---|---|
26 | |
10 | |
8 | |
6 | |
6 |
User | Count |
---|---|
31 | |
10 | |
10 | |
10 | |
9 |