title: How to convert this Simple SQLServer statement into MySQL statement?
body: <p>Given a table that has 3 columns: C1, C2, C3</p>
  
  <pre>
  <b>C1 - C2 - C3</b>
  M  - is - M1
  N2 - is - N3
  M2 - is - M3
  M3 - is - M4
  N1 - is - N2
  M1 - is - M2
  N  - is - N1
  </pre>
  
  <p>How to convert this Simple SQLServer statement into MySQL statement:</p>
  
  <pre><code>declare @searchString varchar(32) = 'M';
  with cte(results) as
  (
      select C3 from Tbl where C1 = @searchString
      union all
      select t.C3 from Tbl t inner join cte c on c.C3 = t.C1 
  ) select * from cte;
  </code></pre>