title: SQL - Join tables with modified data
body: <p>So, I have two tables in SQL Sever 2008 R2:</p>
  
  <pre><code> Table A:
  
   patient_id   first_name   last_name   external_id
   000001       John         Smith       4753-23314.0
   000002       Mike         Davis       4753-12548.0
  
   Table B:
  
   guarantor_id   visit_date   first_name   last_name
   23314          01/01/2013   John         Smith
   12548          02/02/2013   Mike         Davis
  </code></pre>
  
  <p>Notice that the guarantor_id from Table B matches the middle section of the external_id from Table A. Would someone please help me strip the 4753- from the front and the .0 from the back of the external_id so I can join these tables?</p>
  
  <p>Any help/examples is greatly appreciated.</p>