简体   繁体   English

Power BI 合并和与或筛选

[英]Power BI combine and with or filter

I need to filter a table.我需要过滤一个表。 Maybe with a Formula which would look kind of like this:也许有一个看起来像这样的公式:

Filter = IF ( table[column] contains ("A" && "B") || ("A" && "C"), table[column] )

or maybe like this:或者可能是这样的:

= Table.SelectRows(#"Added Custom",
      each Text.Contains([column], "A" and "B") or Text.Contains([column], "A" and "C")
  )

But none of these work.但这些都不起作用。 Thank you for your help.谢谢您的帮助。

Your M code isn't too far off.你的 M 代码离你不远了。 Try this after the each :each之后试试这个:

( Text.Contains([column], "A") and Text.Contains([column], "B") ) or
( Text.Contains([column], "A") and Text.Contains([column], "C") )

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM