On 7/16/06, David Balmain <[EMAIL PROTECTED]> wrote:
> > Don't apologize man, you've done an exceptional job with it so far.
> > The filter I was trying to add would filter based on location, so I'm
> > not sure that It could be done easily using a query-filter. It takes a
> > latitude, longitude, and radius, then filters for records that are
> > with the radius...think that's doable with the builtin filters? I
> > guess I could do it with a bounding box instead, but I'd prefer to
> > keep it accurate...Anyways, I'll try the rferret route for now, and
> > hopefully by the time this application goes to production, the c
> > version will be fixed up. Thanks for your help.
>
> That is a perfect example of what you can't use the QueryFilter for. I
> may even use it as an example in the documentation. Thanks and good
> luck with the pure Ruby version.
>
> Cheers,
> Dave
> _______________________________________________
> Ferret-talk mailing list
> [email protected]
> http://rubyforge.org/mailman/listinfo/ferret-talk
>

I tried out the pure ruby version, but I'm having a little bit of
trouble wrapping my head around how to write the filter. It seems that
some stuff has changed internally since the sample code that I found
at tourb.us was written. I tried looking at the RangeFilter code, but
it seems to be solving too different a problem to really be useful as
a guide. Do you know of any other filters, or have any pointers to how
I would go about writing this filter? It seems really simple, just
does a calculation on two of the fields, but because it's not
iterating through terms, the RangeFilter code doesn't offer me much
help. If you offer some pointers and I manage to get it working, I'd
be happy to send you a copy to use as a sample, though it seems like
the kind of thing you'd probably be able to write in a few minutes...

-- 
Cheers,
Jordan Frank
[EMAIL PROTECTED]
_______________________________________________
Ferret-talk mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/ferret-talk

Reply via email to