hql « MySQL « JPA Q&A





1. hibernate, mysql    stackoverflow.com

i have the following hql query:

UPDATE TaskAssessment taskAssessment 
SET taskAssessment.activeFlag = false 
WHERE taskAssessment IN 
(
SELECT taskAssessment2 
FROM TaskAssessment taskAssessment2 
Where taskAssessment2.activeFlag = true 
AND taskAssessment2.patient.id 
AND taskAssessment2.needsLevel.careNeed = :careNeed
)
but its ...

2. MySql to HQL    coderanch.com

3. HQL having aggregation mysql    forum.hibernate.org

4. Problem with HQL and MySQL    forum.hibernate.org

Beginner Joined: Mon Dec 29, 2003 12:49 pm Posts: 41 Location: Boston, MA Hey guys, I had hbm2java generate domain classes and Finder classes based on my mapping. The HQL in the Finder doesn't seem to want to work. I'm using MySQL v4.0.17 and the latest version of org.gjt.mm.mysql.Driver. I'm also using Struts and the HibernatePlugIn slightly modified, but this seems ...

5. translate sql (from mysql) to hql    forum.hibernate.org

hi, I have a problem to translate this sql to hql: Code: select l.loan_id as loan, p0.amount as amount, ...

6. IfNull (MySQL) and HQL    forum.hibernate.org

Hi, I'm translating an SQL query to HQL (for a MySQL DB). It uses a series of outer joins and the ifnull function to translate nulls to known values in order that every row is returned (not just those containing non-nulls): Does hibernate support something like the ifnull function or do I have to uses a native SQL query in this ...

7. HQL : From .. OK with MS_SQLServer but not with MySQL    forum.hibernate.org

Hello, I am running a test on MS SQL Server and MySQL4 with Hibernate3. Using their own hql dialect I've got a table core_password_logs like this : (class_id, item_id, version, .....) This is OK in MS SQL Server Code: SELECT * FROM core_password_logs V WHERE ...

8. HQL: MySQL Conditional logic issues    forum.hibernate.org

Hibernate version: 3 HQL: Code: select f from ErrorFact f left join fetch f.time time where 1=1 and if ( time.year = :Integer2 , if ( time.month = :Integer3 , if ( (time.day is null) or (time.day = :Integer4) ...

9. Different HQL behaviour with Oracle9 and MySql    forum.hibernate.org

Newbie Joined: Wed Apr 19, 2006 10:45 am Posts: 2 Location: Zurich, Switzerland Hello everybody, I have been using Hibernate 3 for a short time so I am not very experienced. I am actually using it with Spring but I don't think it has anything to do with my problem. Here it is : I have a very simple query that ...





10. Help with HQL with MySQl    forum.hibernate.org

11. HQL being sent to MySQL server?    forum.hibernate.org

Am trying to execute this code: Code: .... .... String queryString = "FROM ImageProcessRequest WHERE entityType = :entityType AND entityId = :entityId"; Session session = this.vandelayConfiguration.getDbContextConfig().getDbContext().currentSession(); Query query = session.createQuery( queryString ); query = query.setString("entityType", obj.getClass().getSimpleName() ); query = query.setString( "entityId", obj.getId().toString() ); .... .... Hibernate version: 3.2 Stack Trace: I get the follwing error: Code: 12642 DEBUG org.hibernate.hql.ast.QueryTranslatorImpl [216] - ...

12. Hi Iam unable to write a HQL for Temporary table in mysql    forum.hibernate.org

Hi Iam unable to write a HQL for Temporary table in mysql. Here is my query SELECT outer21.user_id, outer22.user_game_status, outer21.user_game_start_time FROM (SELECT user_id, user_game_start_time FROM user_current_game_details_master u WHERE current_game_id = (SELECT MIN(current_game_id) FROM user_current_game_details_master u1 WHERE u.user_id = u1.user_id AND u.user_id='reddy' GROUP BY u.user_id)) outer21 JOIN (SELECT user_id, user_game_status FROM user_current_game_details_master u WHERE u.user_game_start_time = (SELECT MAX(user_game_start_time) FROM user_current_game_details_master WHERE day_id ...

13. Iam unable to write a HQL for Temporary table in mysql.    forum.hibernate.org

Hi Iam unable to write a HQL for Temporary table in mysql. Here is my query SELECT outer21.user_id, outer22.user_game_status, outer21.user_game_start_time FROM (SELECT user_id, user_game_start_time FROM user_current_game_details_master u WHERE current_game_id = (SELECT MIN(current_game_id) FROM user_current_game_details_master u1 WHERE u.user_id = u1.user_id AND u.user_id='reddy' GROUP BY u.user_id)) outer21 JOIN (SELECT user_id, user_game_status FROM user_current_game_details_master u WHERE u.user_game_start_time = (SELECT MAX(user_game_start_time) FROM user_current_game_details_master WHERE day_id ...