Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Tommyvhod
Helper II
Helper II

number of ids on work stations

Hi all.

 

I would like to count the number of IDs on each working stations. 1 ID goes trough all working stations and I would like to see the actual status of the product. E.g:

Work st.ID 
11101 
21101 
31101 
41101 
51101 
61101 
71101*
11102 
21102 
31102*
11103 
21103 
31103 
41103 
51103 
61103 
71103 
81103*
11104 
21104*
11105*

 

All IDs got trough work station 1. But only 1103 got trough work station 8 ( last work stations marked with star)

 

I would like count the number of IDs on each work station but only the highest work station. So I would like to see the number of stars ( number of IDs on last work stations)

 

I was only able to count all IDs on each work stations ( so 5 IDs on 1 ,4 IDs on 2 , 3IDs on 3 and so on)

My goal is to show that work station 1 - 1ID, 2-1ID, 3-1ID,4-0ID,5-0ID,6-0ID,7-1ID,8-1ID

 

Thank You

1 ACCEPTED SOLUTION

Try ALLEXCEPT to preserve your filters perhaps.


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

5 REPLIES 5
Greg_Deckler
Super User
Super User

God help me, I think I understand this... 🙂

 

 

Measure 2 = 
    VAR __WorkSt = MAX([Work st.])
    VAR __table = SUMMARIZE(ALL('Table5'),[ID],"__Max",MaX([Work st.]))
    VAR __count = COUNTROWS(FILTER(__table,[__Max] = __WorkSt))
RETURN
    IF( ISBLANK(__count), 0 , __count)

 

 

See attached, Page 3, Table5


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Thank you for the quick reply. Yes in the table you created seems to work. I added to my table and it shows wrong number. Probably becouse I have slicers mon " Table5" and with ALL it removes the filters. ( i have a slicer for product name and status, with that I am unable to filter out the finished parts and see only the WIP)

Try ALLEXCEPT to preserve your filters perhaps.


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

I added ALLEXCEPT; but here I should add all the columns which are filtered on my dashboard? Becouse I tried that and now I should have 19pcs in WIP and this shows 813 🤔🙂

I tried ALLSELECTED with this it removes the filter from the formula but keeps the slicers on the Page.

 

Finally.... it works.... thank You very much

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

Check out the July 2024 Power BI update to learn about new features.

July Newsletter

Fabric Community Update - July 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors