Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between Text.Split and Text.SplitAny?

Tags:

powerquery

m

The difference between Text.Split and Text.SplitAny is not clear to me. They both seem to use the same syntax and do the same thing. Would someone please explain the difference(s) between them to me?

like image 202
Marc Pincince Avatar asked Mar 10 '23 03:03

Marc Pincince


1 Answers

Text.Split splits a text at the supplied delimiter (which can contain multiple characters), while Text.SplitAny splits the text at each individual character in the supplied Delimiter.

E.g. Text.Split("MarcelBeug","ce") returns

Mar

lBeug

While Text.SplitAny("MarcelBeug","ce") returns

Mar

lB

ug

like image 139
MarcelBeug Avatar answered Mar 25 '23 07:03

MarcelBeug