Skip to main content.
home | support | download

Back to List Archive

Re: Combining stem/non stem removing dups in perl

From: Brad Miele <brad(at)not-real.auroraquanta.com>
Date: Thu Nov 04 2004 - 17:56:30 GMT
ok,

And bear with me here, because I have a proclivity for denseness :)

I don't need to look at them all at once. I just
> want a small chunk at a time to show the user. swish-e is faster at
> searching and sorting than perl will be,

so, if my $indexes variable looks something like:

"nonstemmed.index stemmed.index"

and I apply the keyword query "elevator",

my hits value is say 700, which is the total results of the combined
indexes sorted by whatever method was supplied.

so in order to display the first x results, it seems to me like i would
have to push the entire result set into an array, and then remove the
duplicate "ids", then use the size of that array in items to redefine the
total, determine pageination, etc, and finally loop through the array
until record x.

and then, for the next 20 records, do the same thing, but start my looping
at record x + 20. I just can't get my head around how to get swish to do
the page stuff for me. now, what i ultimately want to do is push the
stemmed stuff towards the end, and I think that I will use prog to set a
sort like stemmed with a value of 1, but i still need to avoid the
records.

sorry, my understanding of perl structures, and structure in general ;)
may be just too limited to get it. for now, my solution has been to do
this:

http://tools.ipnstock.com/SwishSearch/?Keywords=elevator&spec_idx=&method=keywords&color=&max_res=16

and allow the user to toggle between sets under the guise of relevance.

thanks again for all of your help.

Brad
------------------------------------------------------------
 Brad Miele
 Technology Director
 AuroraPhotos.com
 (207) 828-8787 x110
 bmiele@auroraphotos.com

 God made machine language; all the rest is the work of man.


On Thu, 4 Nov 2004, Peter Karman wrote:

>
>
> Brad Miele wrote on 11/04/2004 11:03 AM:
>   I didn't know if a resultset
> > of say 10,000 records(combined stem and non), would be cumbersome to
> > manipulate.
> >
>
> I imagine a result set that big WOULD be cumbersome (and memory
> intensive) if you loaded it all into memory at once. But do you? I might
> have 10,000 hits, but I don't need to look at them all at once. I just
> want a small chunk at a time to show the user. swish-e is faster at
> searching and sorting than perl will be, IF you've got properties
> indexed that help that sort of thing.
>
> I return about a couple dozen properties with each result, some long (>
> 100 char) text strings, some short.
>
> --
> Peter Karman . http://www.cray.com/craydoc/ . karman(at)not-real.cray.com
> "I love deadlines. I love the whooshing sound they make as they go by."
>          - Douglas Adams
>
Received on Thu Nov 4 09:56:40 2004