• 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
Re: [SOLVED] Re: Sort problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [SOLVED] Re: Sort problem


  • Subject: Re: [SOLVED] Re: Sort problem
  • From: Art Isbell <email@hidden>
  • Date: Fri, 15 Apr 2005 11:52:00 -1000

On Apr 15, 2005, at 11:43 AM, David Holt wrote:

EOSortOrdering timeOrdering = EOSortOrdering.sortOrderingWithKey ("lastPost.timestamp", EOSortOrdering.CompareDescending);

If I understand your application logic correctly, each time you invoke lastPost() as occurs in the above sort, the last post for each Topic will be recomputed which might be expensive. You might want to consider caching the last post to avoid unnecessary recomputations. When a new post is added to a Topic, you could either set it to be the last post (if that makes sense) or set the cached last post to null so lastPost() will recompute it.


Aloha,
Art

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: [SOLVED] Re: Sort problem
      • From: David Holt <email@hidden>
References: 
 >Re: Sort problem (From: David Holt <email@hidden>)
 >[SOLVED] Re: Sort problem (From: David Holt <email@hidden>)

  • Prev by Date: [SOLVED] Re: Sort problem
  • Next by Date: Re: [SOLVED] Re: Sort problem
  • Previous by thread: [SOLVED] Re: Sort problem
  • Next by thread: Re: [SOLVED] Re: Sort problem
  • Index(es):
    • Date
    • Thread