Matthew McGrew wrote:
> 1) I would like to search indexes on two or more different models with
> 1 call.  I know I can do ThinkingSphinx.search, but that is
> everything.  I'm going to surmise this is possible, yet I can't find
> it.

Try ThinkSphinx.search("blah", :class => [Product, User])

> 2) I also would like to only match the beginning of the data field.
> e.g. a search for "apple" matches "apple a day" but not "big apple".
> I've been through the docs but just not getting the right approach.

Section 4.3 of the docs @ http://www.sphinxsearch.com/docs/current.html
says sphinx 0.9.9-rc2 supports the following search syntax for "field
starts with": '^hello world'.

If you're running, 0.9.9-rc2, try something like:

  ThinkSphinx.search("^apple", :match_mode => :extended)

-- James Healy <jimmy-at-deefa-dot-com>  Tue, 01 Sep 2009 13:14:53 +1000

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Thinking Sphinx" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/thinking-sphinx?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to