title: How to use substring in order by
body: <p>I have the following query to select the domain names that have three levels separated by two dots:</p>
  
  <pre><code>select domainname from db.table
  where criteria like ('*.com')
  AND domainname like ('%.%.%');
  </code></pre>
  
  <p>Now, I need to order the results by the .%.% part of the domain name and not %.%.%. How can I add this to my query ?</p>