Since I am using Oracle as my database, it seems that one way I could solve my question is to:
1. sort in a subquery
2. determine which item in the subquery matches the id of 'the object i want to know the sorted index of'.
3. return the value of the matching magic/psuedo-column rownum
I see that rownum is used 'under the hood' for pagination in Hibernate when using Oracle.
However, I can't seem to configure even a simple query query correctly.
Code:
select dog.rownum from Dog as dog where ...
Any suggestions for how to properly access rownum in my own HQL queries?