Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] Order By Child Column modifies Join Order

Not sure if these are JPQL, or SQL, they don't look like valid either.

Could you include the real code to the queries you are executing, and the
real SQL that EclipseLink is generating.



tch wrote:
> 
> We're getting some odd behavior:
> Some JPQL like this
> 
> Select parent.label, child.label2
> FROM parent
> LEFT JOIN child
> 
> With the expression API if we add an order on child.label2, the query
> is rewritten like this:
> 
> Select parent.label, child.label2
> FROM child
> LEFT JOIN parent
> order by child.label2
> 
> Is there some hint that we have to use to tell EL to not rewrite like
> this when ordering by a child column? Obviously query 2 is very
> different from query 1.
> 
> Thanks
> 
> ./tch
> _______________________________________________
> eclipselink-users mailing list
> eclipselink-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/eclipselink-users
> 
> 


-----
http://wiki.eclipse.org/User:James.sutherland.oracle.com James Sutherland 
http://www.eclipse.org/eclipselink/
 EclipseLink ,  http://www.oracle.com/technology/products/ias/toplink/
TopLink 
Wiki:  http://wiki.eclipse.org/EclipseLink EclipseLink , 
http://wiki.oracle.com/page/TopLink TopLink 
Forums:  http://forums.oracle.com/forums/forum.jspa?forumID=48 TopLink , 
http://www.nabble.com/EclipseLink-f26430.html EclipseLink 
Book:  http://en.wikibooks.org/wiki/Java_Persistence Java Persistence 
-- 
View this message in context: http://www.nabble.com/Order-By-Child-Column-modifies-Join-Order-tp24938507p25045513.html
Sent from the EclipseLink - Users mailing list archive at Nabble.com.



Back to the top