Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Filter out rows with multiple conditions

Hi, 

 

I am having troubles with filtering out a few rows from my data set. I have created a small example below. I want to exclude the rows where [ContractNO] = MM005 and where [Number] = 100, 101, 102, 103 and 104. The expected result are seen in picture 2. 

 

And the expected outcome to:

Hope someone can help me.

 

Best regards

Line

  • Anonymous , Create a measure like this one and use it with other non summarized columns

     

    countrows(filter(Table, not([ContractNO] = "MM005" && [Number] in{ 100, 101, 102, 103 , 104})))

  • Hi Anonymous ,

    This might be because the Number Column might be an integer. Try changing it to Text Datatype.

3 Replies

  • Anonymous , Create a measure like this one and use it with other non summarized columns

     

    countrows(filter(Table, not([ContractNO] = "MM005" && [Number] in{ 100, 101, 102, 103 , 104})))

    • Anonymous's avatar
      Anonymous
      Not applicable

      I have tried to create the measure in my dataset, but get an error saying that the function does not support comparing values of type integer with values of type text. 

  • Hi Anonymous ,

    This might be because the Number Column might be an integer. Try changing it to Text Datatype.