title: SQL update column1 with column2 in another table that have same word
body: <p>I have two tables:</p>
  
  <pre><code>SELECT * 
  FROM providerpaymentdetails, remarkcode;
  </code></pre>
  
  <p>providerpaymentdetails has columns:
  <strong>id, amount, text, remark_code_id</strong></p>
  
  <p>remarkcode has columns:
  <strong>id, code</strong></p>
  
  <p>if providerpaymentdetails.text has <code>text</code> that contains "B2", "B3", I want to update the <code>remark_code_id</code> with the correlating id from <code>remarkcode.code</code> which contains "B2", "B3", etc. </p>
  
  <p>This is the code I have right now, but this is not working. Any ideas?</p>
  
  <pre><code>SELECT * FROM providerpaymentdetails, remarkcode;
  UPDATE providerpaymentdetails
  set REMARK_CODE_ID = remark_code.id 
  WHERE providerpaymentdetails.TEXT LIKE '%B2'
  </code></pre>