Lucas Tarquino Posted March 29, 2019 Share Posted March 29, 2019 I'm trying to add a calculated column to create abbreviations for a stringusing a regular expression in the RXReplace function:RXReplace([Hospital_Name],"B[a-zA-Z'-]+","","g"). However, I get an error stating "Invalid escape sequence: "B"." which seems to not recognize the not word boundary. The function does recognize the word boundary "b". Why is this not working Is there an alternative to "B" or a different approach to abbreviate a phrase (e.g., "This Is A Phrase" > "TIAP") Link to comment Share on other sites More sharing options...
Lucas Tarquino Posted March 29, 2019 Author Share Posted March 29, 2019 Please see the following StackOverflow post for the question and answer https://stackoverflow.com/questions/55415866/rxreplace-function-gives-in.... The correct function call is: RXReplace([Hospital_Name], "\B[a-zA-Z'-]+|\W+", "", "g"). Link to comment Share on other sites More sharing options...
Gaia Paolini Posted April 1, 2019 Share Posted April 1, 2019 Thanks for cross-linking! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now