[hibernate-issues] [Hibernate-JIRA] Créée: (HHH-2389) Improving DB2 dialect

Nicolas Billard (JIRA) noreply at atlassian.com
Mon Jan 29 04:18:19 EST 2007


Improving DB2 dialect
---------------------

         Key: HHH-2389
         URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-2389
     Project: Hibernate3
        Type: Improvement

  Components: query-hql  
    Versions: 3.2.1    
 Environment: Development based on v 3.2.1
    Reporter: Nicolas Billard
    Priority: Minor
 Attachments: DB2Dialect.java

The class joined to this issue overrides the DB2 dialect. The dialect included in hibernate doesn't work very well when you want to limit returned results (when you call setFirstResult and / or setMaxResults on a query) :
- the instructions "fetch first XXX row only is not used
- a temporary table is used when it's not usefull
- when you have subselects, an exception can occur if subselects have order by clause (because of the getRowNumber method, not corrected here).

This version of getLimitString() method generates faster requests (tests made on a table of 300000 rows shows that fetching rows from 20 to 30 takes 0.3 seconds with original version, 0.02 with this one).


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira




More information about the hibernate-issues mailing list