title: Masking ID and Name in SQL
body: <p>I have a use case where there is a free text field and the user id in the format ab12345 (fixed) and name (dynamic) can appear anywhere in the string.</p>
  <p>Now I need to replace the ab12345 with xxxxxxx and the names also with XXXX wherever I find them in the string.</p>
  <p>I used:</p>
  <pre class="lang-sql prettyprint-override"><code>select *
  from dbo.TEST
  WHERE DESCRIPTION like '%[a-zA-z][a-zA-Z][0-9][0-9][0-9][0-9][0-9]%';
  </code></pre>
  <p>to get the user id ab12345 but I am unable to write the replace function for this since the result is dynamic.</p>
  <p>Same with the name as well.</p>