On Thu, Jul 19, 2007 at 05:40:45AM +0200, Chengcai He wrote:
> one more question:
> in the Model
> acts_as_ferret({ :fields => {:username => {:store => :yes, :boost =>
> 30}, :subject => {:store => :yes, :boost => 20}, :body => {:store =>
> :yes, :boost => 10}}, :remote => true }, { :analyzer =>
> Ferret::Analysis::RegExpAnalyzer.new(/./, false) })
>
> def username
> return self.user.login
> end
>
> search as:
> @total, @topics = Topic.full_text_search(params[:searchTerms], {:page =>
> (params[:page]||1)}, {:conditions => @conditions})
>
> if i input a query term to search, i will got the result: @total = 14,
> @topics.length = 12
> but when i input the user login to search the topics posted by the user,
> it got:
> @total = 14, @topics.length = 0. It just display the paginate things,
> but none of the result topic displayed!
>
> I'm totally lost!
Look at your log files, see what queries ferret runs against the index,
and see what sql statements are issued to your DB. I guess without the
conditions everything is ok?
cheers,
Jens
--
Jens Krämer
webit! Gesellschaft für neue Medien mbH
Schnorrstraße 76 | 01069 Dresden
Telefon +49 351 46766-0 | Telefax +49 351 46766-66
[EMAIL PROTECTED] | www.webit.de
Amtsgericht Dresden | HRB 15422
GF Sven Haubold, Hagen Malessa
_______________________________________________
Ferret-talk mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/ferret-talk