Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi,
so there were data entries in this column that were separated in the following form:
pigs - type - cats
but some entries have
pigs - types - cats
pig-s - type - cats
pigs - type - cats -oct-11-2017
So unfortunately I cannot separate this column by delimiter.
What is the best way of doing this? Do you recommend an if statement that checks to see if there is a '-' more than 3 times ?
I would also need to write something that checks for the first several letters to normalize 'type' and 'types'.
What is the name of this function?
Hi @Nusc
You can get the text before the 3rd delimiter with this function: https://docs.microsoft.com/en-us/powerquery-m/text-beforedelimiter
You could add an extra - at the end of each string before calling this function
For the other problem, probablt this function can help you: https://docs.microsoft.com/en-us/powerquery-m/text-replace
Did I answer your question correctly? Mark my answer as a solution!
Proud to be a Datanaut!
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
76 | |
76 | |
56 | |
38 | |
34 |
User | Count |
---|---|
99 | |
56 | |
51 | |
44 | |
40 |