5 Replies Latest reply on May 18, 2006 7:09 PM by epbernard

    executeUpdate problem- (bug?)

    armita

      Trying to execute this query:

      Query query = em.createQuery(" update Activity " +
       " set startDate=:startDate, endDate=:endDate" +
       ", actualStartDate=:actualStartDate, actualEndDate=:actualEndDate " +
       "where tag=:tag and ne.code=:code ");
      

      I am getting SQL error. The problem is Hibernate creates this Query:
       update Activity, set startDate=?, endDate=?, actualStartDate=?, actualEndDate=? where tag=? and code=?
      

      and the "," after Activity makes MySQL confused and therefore could not understand the command.
      Is it a bug or I am doing something wrong here?