• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Sorting Relationed Records
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Sorting Relationed Records


  • Subject: Sorting Relationed Records
  • From: "A. Uchida" <email@hidden>
  • Date: Wed, 21 Jul 2004 01:11:16 +0100

Posted again, because the original message didn't have subject.

Hi there,

I am doing a practice of WO application using MacOSX 10.3, Xcode and WO5.2.
I've faced a problem of EOSortOrdering and can't work out by myself.


From a previous list view page (Fetch by WODisplayGroup) and pass a record
to a next page. The record (EntityA) has to-many relationship to EntityB.
My part of the code is as follows.
Whatever I tried at this moment, " java.lang.NullPointerException" at
the first line of the following codes. (aKeyOfEntityA.relations() doesn't return any records)
In the next page, there is no WODisplayGroup. I used to bind aKeyOfEntityA.relations to
the list of WORepetition and this shows a list of related EntityB records.


Any help would be very much appreciated.


NSArray anArray = new NSArray(aKeyOfEntityA.relations());
EOSortOrdering so1 = EOSortOrdering.sortOrderingWithKey("ep_date", EOSortOrdering.CompareAscending);
EOSortOrdering so2 =EOSortOrdering.sortOrderingWithKey("ep_Category",
EOSortOrdering.CompareAscending);
NSArray soList = new NSArray(new Object[]{so1, so2});
sortResult = EOSortOrdering.sortedArrayUsingKeyOrderArray(anArray, soList);



A. Uchida
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.



  • Follow-Ups:
    • Re: Sorting Relationed Records
      • From: Nathan Dumar <email@hidden>
  • Prev by Date: Re: Question on editing contexts
  • Next by Date: Re: Using Selectors in EOQualifier format
  • Previous by thread: Re: supplying an initial selection in WOPopUpButton and its kin
  • Next by thread: Re: Sorting Relationed Records
  • Index(es):
    • Date
    • Thread