日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

50、Power Query-Text.Contains的学习

發布時間:2025/3/20 编程问答 48 豆豆
生活随笔 收集整理的這篇文章主要介紹了 50、Power Query-Text.Contains的学习 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

比如現在有這樣一個需求,需要篩選某列規格里面的一些內容。


比如我們要篩選出包含“110”以及“123”以及“CF”的規格,當然用條件格式也是可以的。

若是兩個包含,我們可以直接篩選得到,如下圖操作。



沒錯,就是文本篩選器里面的“包含”。


那么最后一個條件該如何引入呢?


我們不妨直接看它生成的公式,是不是豁然開朗?

= Table.SelectRows(更改的類型, each Text.Contains([型號], "110") or Text.Contains([型號], "123"))

直接添加"OR"即可。

= Table.SelectRows(更改的類型, each Text.Contains([型號], "110") or Text.Contains([型號], "123") or Text.Contains([型號], "CF"))


那么我們就來看看這個好用的Text.Contains()函數。

This topic applies to the Power Query Formula Language which can be used with?Power Query?and?Power BI Desktop?to build queries that mashup data. See the list of?function categories.

Returns true if a text value?substring?was found within a text value?string; otherwise, false.

Text.Contains(string as nullable text, substring as text, optional comparer as nullable function) as nullable logical Argument Description
string The text to parse.
substring The text to search for.
optional comparer The optional culture aware comparer function can be provided.

簡單例子: Text.Contains("abc", "a") equals true Text.Contains("abc", "d") equals false

清楚了這個函數的用法,當然“開頭為”和“結束為”也大同小異啦。

Text.StartsWith()

Text.EndsWith()

總結

以上是生活随笔為你收集整理的50、Power Query-Text.Contains的学习的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。