title: Use DATE_ADD in Hibernate @Formula
body: <p>I'm trying to use DATE_ADD (Mysql) function in a Hibernate Formula.</p>
  
  <p>This is my field:</p>
  
  <pre><code>@Formula(value = "(SELECT DATE_ADD(v.dataAndata, INTERVAL v.minutiTrasportoAndata MINUTE) FROM VenditaB2B v WHERE v.id = id)")
  private Date dataImbarco;
  </code></pre>
  
  <p>Unfortunately when Hibernate does the query it translates the query as:</p>
  
  <pre><code>(SELECT DATE_ADD(v.dataAndata, venditab2b0_.INTERVAL v.minutiTrasportoAndata venditab2b0_.MINUTE) FROM VenditaB2B v WHERE v.id = venditab2b0_.id) as formula5_
  </code></pre>
  
  <p>and of course it's wrong because it believes that MINUTE and INTERVAL are columns of my table VenditaB2B.
  I tried with single and double quotes without luck. </p>
  
  <p>There is a way to solve this problem? Thanks!</p>