Forum Discussion

zack's avatar
zack
Frequent Visitor
9 years ago
Solved

Create column based on occurence of string value contained in lookup table

I need to show how many transactions have payees from a watch list. There are two files, the monthly transaction file and a watch list containing essentially one field.   The primary file contains...
  • Anonymous's avatar
    Anonymous
    9 years ago

    Hi zack,

     

    You can use contains function to check if the value is contained in search table.

     

    Measure:

     

    IsContains = 
    var currItem= LASTNONBLANK('CurrentTable'[ColumnName],[ColumnName])
    return
    CONTAINS(SearchTable,SearchTable[ColumnName],currItem)

     

     

    Then drag above measure and the watch item column to a table visaul.

     

    Regards,

    Xiaoxin Sheng