I am trying to insert a space in my text in the column 'CountyX'. How can I do that with RegEx? Can someone help me please?
Solved! Go to Solution.
Hi @Kwaku_Od ,
Can you provide a sample input and a desired output, as from the provided screenshots it's hard to tell what you're trying to do. Are you trying to add a space before the second capital letter in your CountyX column?
EDIT : If that's the case and County is present and appears last in all your records, you can try replacing that very text with a space and then add the string "County" after it. No need to use a regex tool, a formula tool will do it.
Thanks,
Angelos
Hi @Kwaku_Od
An equivalent regex would be
regex_replace([Field1],"(.*?)(County)","$1 $2")
If you're using the Regex tool
If you're modifying the input string directly, remember to increase its length using a select so you don't end up dropping the "y" from "County"
Dan
Hi @Kwaku_Od
Why not just use replace function like this
Replace([County], " Total", "")
Hope this helps : )
Hi @Kwaku_Od
Can you provide some sample input and expected output it will help us get a better understanding of the usecase. I will try to provide you a solution early as possible 🙂
Thank you ! This worked!
Happy to help : ) @Kwaku_Od
Cheers and have a nice day!
Thanks for the simpler solution, @atcodedog05!