Thanks for replying. I was aware of this but when we have a query that returns large number of rows then its not a good idea to get the list and then sort it.
Thanks,
Denna
Neil Pierson <neil.pierso..mail.com> wrote:
To the best of my knowledge, relationships do not return objects with an order. You can do something like this:
List list = someObject.getRelatedObjects;
Ordering ord = new Ordering(RelatedObjects.SOME_PROPERTY, Ordering.ASC);
ord.orderList(list);
On 11/7/05, Dhruti Ramani <dhrutiraman..ahoo.com> wrote: I am using cayenne1.1 and Postgresql as my database. I have two objects Address and USState and 1 to M relation between them. Every time i print a list of USStates it prints in different order, like sometime NY, NJ, and sometime NJ, NY. I am not using any Ordering. Is there a way to tell cayenne that get the list in some order? For getting the list i am using method that cayenne provides.
Thanks,
Denna
---------------------------------
Yahoo! FareChase - Search multiple travel sites in one click.
---------------------------------
Yahoo! FareChase - Search multiple travel sites in one click.
This archive was generated by hypermail 2.0.0 : Mon Nov 07 2005 - 15:26:15 EST