title: Grails query LEFT JOIN on table with no domain relations
body: <p>I'm new to Grails and I'm stuck with this problem for hours. Thanks in advance for you help!</p>
  
  <p>Here is my question:</p>
  
  <p>I have a database with two tables</p>
  
  <ol>
  <li><strong>PROJECT</strong> </li>
  <li><strong>LIKES</strong></li>
  </ol>
  
  <p>As you can guess a user has the right to <em>Like</em> a <em>Project</em>. 
  In the Domain Class <strong>Project</strong> there is <strong>NO</strong> relations (<em>belongsTO, hasOne, etc..</em>)
  Same in the Domain Class <strong>Likes</strong></p>
  
  <p>In the database the table <strong>LIKES</strong> has a field <strong>project_id</strong> but it is <strong>not</strong> set as a foreign_key. It is this made this way for right purpose.</p>
  
  <p>Now I need to execute a native SQL query with grails which is really simple and returns the result expected. </p>
  
  <p><em>The result is all projects that have Likes or not</em></p>
  
  <p>Here is the query :
  </p>
  
  <pre><code>SELECT project.name, Likes.likes
  FROM project
  LEFT JOIN Likes
  ON project.id = likes.project_id;
  </code></pre>
  
  <p>I cant find a way to convert this SQL query to HQL.
  It seems that HQL works on Domain instance and the fact that there is no relation between the domains return an error like "the Domain Project has no Likes attribute" which is correct.</p>
  
  <p>Is there a way to get the right result with one query or do I need to do two query and build an Array with the result programmatically ?</p>
  
  <p>Thanks for you help</p>