Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago

Display non matching values in a table

Hi Everyone

 

Kindly assist, I am new to power bi.

 

I have 3 queries (Employee Data, Leave  Taken and Leave Balance).All of them are linked through an employee ID.

 

I  need to display the total number of leave days and  leave type from Leave Taken  along with leave balances .  The challenge is  for some employees the leave type is not the same, using the lookupvalue funtion I am able to get the matching value. But now I want to display the non matching value as well in a separate row.

 

New Time Off Plan = LOOKUPVALUE('OML Leave Taken'[Time Off Type for Time Off Entry],'OML Leave Taken'[Time Off Type for Time Off Entry],'OMl Leave Balance'[Time Off Plan])
 
As depicted below the total number of days is 8 .Therefore the other 4 days belongs to a different time off plan.

 

 

Your response will be highly appreciated.

 

 

3 Replies

  • v-luwang-msft's avatar
    v-luwang-msft
    Icon for Community Support rankCommunity Support

    Hi Anonymous ,

    Test the below:

    Match =
    IF (
        LOOKUPVALUE ( 'OML Leave Taken'[Time Off Type for Time Off Entry],
      'OML Leave Taken'[Time Off Type for Time Off Entry], 'OMl Leave Balance'[Time Off Plan])
            = BLANK (),
        "Not A Match",
        "Match"
    )

     

    If question not solved ,could you pls share a sample data and expected output?

     

     

    Best Regards

    Lucien

  • v-luwang-msft's avatar
    v-luwang-msft
    Icon for Community Support rankCommunity Support

    Hi Anonymous ,

    Has your problem been solved, if so, please consider Accept a correct reply as the solution or share your own solution to help others find it.

     

    Best Regards
    Lucien