I have a string containing \s\ keyword. Now, I want to replace it with NULL.
select string,REGEXP_REPLACE(string,'\\\s\\','') from test
But unable to replace with the above statement in spark sql
input: \s\help
output: help
want to use regexp_replace

NULLis not something to replace in a string. (3) Do you wantreplace()?s, in your question only one. there is a significant difference as in the question you escape your'and that will definitely break it.