The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hello All,
Simplistic table:
YEAR | COMPANY | OrderNumber |
[YEAR] is linked to a Calander Table which also has [YEAR]
I have two slicers on the page, YEAR and COMPANY
I am trying to create a measure to count the number of OrderNumbers ignoring the COMPANY but keeping the YEAR
NumberofOrders =
CALCULATE
(
DISTINCTCOUNT('Table'[OrderNumber]),
ALL('Table'),
ALLEXCEPT('Calendar','Calendar'[YEAR])
)
However this doesnt seem to work. Any ideas on how to correct?
Thank you
Solved! Go to Solution.
@BugmanJ
Please try
NumberofOrders =
CALCULATE (
DISTINCTCOUNT ( 'Table'[OrderNumber] ),
ALLEXCEPT ( 'Table', 'Calendar'[Date] )
)
@tamerj1 / @ValtteriN
Slight variance on the above. In the Data above, lets say I have an extra coloumn called [TIMETOPRODUCE] but I want that to filter out orders less then 155
NumberofOrders =
CALCULATE (
DISTINCTCOUNT ( 'Table'[OrderNumber] ),
ALLEXCEPT ( 'Table', 'Calendar'[Date] ),
FILTER ( 'Table'[TimeToProduce]<155)
)
Doesnt work, any ideas?
J
NumberofOrders =
CALCULATE (
DISTINCTCOUNT ( 'Table'[OrderNumber] ),
ALLEXCEPT ( 'Table', 'Calendar'[Date] ),
'Table'[TimeToProduce] < 155
)
@BugmanJ
Please try
NumberofOrders =
CALCULATE (
DISTINCTCOUNT ( 'Table'[OrderNumber] ),
ALLEXCEPT ( 'Table', 'Calendar'[Date] )
)
Hi,
Since you want to remove one filter and keep the other try using REMOVEFILTER:
DAX:
I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!
My LinkedIn: https://www.linkedin.com/in/n%C3%A4ttiahov-00001/
Proud to be a Super User!
User | Count |
---|---|
14 | |
11 | |
8 | |
6 | |
5 |
User | Count |
---|---|
28 | |
19 | |
13 | |
8 | |
5 |