title: Regex for replacing all characters excepting last and first non space ones
body: <p>I have emails stored in SAP Hana table column of char datatype. I need to replace all letters and digits with '*' char excepting first and last non-whitespace chars. I wrote the regex like this: regex_replace('abcd@efg.hij', '(?!^)[A-Za-z0-9](?!$)', '*')
  It works fine and I get masked email 'a***@***.**j'.
  But it goes wrong when there are some white spaces at the start and/or the end of the email. For example, if the email string is ' abcd@efg.hij ' the result would be 
  ' ****@***.**** ' while I need ' a***@***.**j '
  Unfortunately, I cannot trim email before regexing.</p>