Dynamic finders with InList and OrderBy issue

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Dynamic finders with InList and OrderBy issue

Paul C
Here is a query  where I thought the OrderBy suffix would work but the generated SQL does not have an order by.  

Any insight on what happened here is greatly appreciated.  I thought it would at least cause an error if the context is not valid for OrderBy.  We are using several recent versions of postgres.

def allLocations = Location.findAllByIdInListOrderByPath(locationArray)

Notice hibernate sql does not have 'order by':

    /* criteria query */ select
        this_.id as id1_20_0_,
        this_.path as path8_20_0_,
        location this_
        this_.id in (
            ?, ?, ?, ?, ?, ?

You received this message because you are subscribed to the Google Groups "Grails Dev Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/grails-dev-discuss/2dc2724c-9f3a-4be8-8df3-db9c511cc6df%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.