title: Referencing field from joined type in update
body: <p>I have a problem with inheritance:</p>
  
  <p>A class Item and a class User witch extends from Item</p>
  
  <pre><code>@Inheritance(strategy= InheritanceType.JOINED)
  @Entity
  @Table(name = "item")
  public class Item{
      ...
      Date lastdate;
  }
  
  @Entity
  @Table(name = "user")
  public class User extends Item{
      ...
      Date logindate
  }
  </code></pre>
  
  <p>And I want to do this query:</p>
  
  <pre><code>update User u set u.lastdate=u.logindate where u.id = ?1
  </code></pre>
  
  <p>But it throw an exception: <code>Unknown column 'logindate' in 'field list'</code>, because it tries to execute this:</p>
  
  <pre><code>update item set lastdate=logindate where (item_id) IN (select item_id from HT_user)
  </code></pre>
  
  <p>How can I reference the item.lastdate and the user.logindate in my HQL Update query?</p>