openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Malte <>
Subject Problem with select performance
Date Thu, 20 Oct 2016 12:54:51 GMT
Hello all!

I have a performance problem getting data from the database. I have a
modeltree with some oneToMany relations (see attached image). If I try to
read only a specific amount of records with the Query#setMaxResults
function, the created sql statements seems the problem.

The first is is correct:
    FROM test_head t0 ORDER BY DESC LIMIT ?

But the following statements, which read the relations, run without any
SELECT,, t1.head_id, t1.text
    FROM test_head t0 INNER JOIN test_lines t1 ON = t1.head_id ORDER

This select produces two full tablescans on the database.

I added a exampleproject as an attachment.

Made I something wrong or is the a bug in openjpa?

Best regards,

PS: I hope you can understand my poor english.

View raw message