title: Regex match that will ignore punctuation within the string
body: <p>** edited **</p>
  
  <p>I'm trying to compare one name from source A (<code>ST MARYS MEDICAL CENTER</code>) with another name from source B (<code>St. Mary's Medical Center: Welcome</code>).  A and B are not arrays.</p>
  
  <p>I would like to retain <code>St. Mary's Medical Center</code>.  In essence, I need to confirm that they are the same institution and 'normalize' the value.</p>
  
  <p>I would like to ignore case, all periods (<code>.</code>), and all apostrophes (<code>'</code>).  If there is a match, I'd like to retain the <strong>matching</strong> value from B.</p>
  
  <p>For example:</p>
  
  <pre><code>&gt; a = "ST MARYS MEDICAL CENTER"
  =&gt; "ST MARYS MEDICAL CENTER"
  
  &gt; b = "St. Mary's Medical Center: Welcome"
  =&gt; "St. Mary's Medical Center: Welcome"
  
  # need help here
  &gt; re = /#{a}[^'.]*/i
  =&gt; /ST MARYS MEDICAL CENTER[^'.]*/i
  
  &gt; re.match(b)[0]
  =&gt; "St. Mary's Medical Center"
  </code></pre>
  
  <p>Assuming that I get the correct regex, will the match include the punctuation?</p>