Forum Discussion

JMHenriques's avatar
JMHenriques
Frequent Visitor
7 years ago
Solved

create new column based on multiple criteria and uniqueID

Hi all :)   Really sorry, complete newbie in DAX... easy to do this in excel but not so much in DAX... So I want to insert a new column that checks for the UniqueID if the 3 trainings have the sta...
  • v-xuding-msft's avatar
    7 years ago

    Hi JMHenriques ,

    You could try to create a calculated column using the formulas below.

    Column = 
    var d1=CALCULATE(COUNT('Table'[Training]),ALLEXCEPT('Table','Table'[UniqueID]))
    var d2=CALCULATE(COUNT('Table'[Status]),FILTER(ALLEXCEPT('Table','Table'[UniqueID]),'Table'[Status]="Completed"))
    return
    IF(d1=d2,"PackComplete","PackNotComplete")
    

    Best Regards,

    Xue Ding

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.