title: How to match part of a field with data in another field with query?
body: <p>I have 2 tables table1 and table2:</p>
  
  <ul>
  <li>table1 contains a field named <code>id</code> with a value <code>1212</code> (example) in it.</li>
  <li>table2 has a field named <code>action</code> with a data like <code>added 1212</code> or <code>updated 1212</code>.</li>
  </ul>
  
  <p>Now check this query.</p>
  
  <pre><code>SELECT t1.*, t2.name
  FROM table1 t1, table2 t2
  WHERE t2.action LIKE 'added t1.id'
  </code></pre>
  
  <p>I want to add the <code>name</code> field in the second table, to first one with the <code>added</code>(<code>updated</code> not needed) data only.
  What is the where clause for this condition?
  How can I query this?</p>