Skip to Content.
Sympa Menu

grouper-dev - RE: [grouper-dev] search and sort columns on member table

Subject: Grouper Developers Forum

List archive

RE: [grouper-dev] search and sort columns on member table


Chronological Thread 
  • From: Jim Fox <>
  • To: Chris Hyzer <>
  • Cc: Shilen Patel <>, Grouper Dev <>
  • Subject: RE: [grouper-dev] search and sort columns on member table
  • Date: Wed, 30 Mar 2011 09:23:37 -0700 (PDT)


Yes, your right.

Jim


On Wed, 30 Mar 2011, Chris Hyzer wrote:

Date: Wed, 30 Mar 2011 09:20:42 -0700
From: Chris Hyzer
<>
To: Jim Fox
<>,
Shilen Patel
<>
Cc: Grouper Dev
<>
Subject: RE: [grouper-dev] search and sort columns on member table


I believe indexes on the sort columns should help in some cases. For
instance, if you're sorting and paging at the same time. Though if we find
out that the benefit is small and folks would rather save the database space,
we can leave them off.

My thinking is that paging results in sorts of a only few hundred records.

Yeah, but it needs to sort all the records and take a page of them, so an
index would help there... right?

In other words, if the records are:

R, F, Q, J, M, T, X

And you want the second page of size two, then if it is indexed, then it
knows the order is:

F, J, M, Q, R, T, X

And if it knows that, then all it has to do is know the size (7), and the
second page of size two is records index 2 and 3 (starting at 0).

If it doesn't know the order, then it needs to order them and do the same
thing, which is harder.

Thanks,
Chris





Archive powered by MHonArc 2.6.16.

Top of Page