title: Create a Table from a SQL Query with Hibernate
body: <p>I have 3 tables that I want to join in a single table <code>collaborator</code> with this Sql query : </p>
  
  <pre><code>select * from (
  select user.id, Project.id, Task.id
  inner join Project on user.join_key = Project.join_key
  inner join  Task  on task.join_key = = Project.join_key
  ) collaborator
  </code></pre>
  
  <p>And I can't seem to find How to.
  I can use this also : </p>
  
  <pre><code>CREATE TABLE Collaborator AS
  SELECT user.id, Project.id, Task.id
  FROM Project p, Task t, User u
  inner join Project on user.join_key = Project.join_key
  inner join  Task  on task.join_key = = Project.join_key.
  </code></pre>
  
  <p>Any help would be appreciated. Thanks</p>