Forum: Ruby-Forum.com Search Failure?

A5dc4e45ad4d75e6a46cb2bbc8aa9e94?d=identicon&s=25 Vincent Tsao (vincentcao)
on 2006-08-20 18:13
I checek out the newest source code from SVN,
it seems my RForum search function does not work ,here is my log
information:

Processing ForumController#search (for 127.0.0.1 at 2006-08-20 23:53:04)
[GET]
  Parameters: {"action"=>"search", "controller"=>"forum",
"forums"=>["1"], "query"=>"come"}
  BlockedIp Load (0.016000)   SELECT * FROM blocked_ips
WHERE (ip = '127.0.0.1') LIMIT 1
  Forum Load (0.000000)   SELECT * FROM forums ORDER
BY site_id, position 
id_score_model array: []
Query: come +forum_id:(1 +deleted:0
Result id_array: [],
result:
Rendering  within layouts/default
Rendering forum/search
  Forum Columns (0.031000)   SHOW FIELDS FROM
forums
Completed in 0.17100 (5 reqs/sec) | Rendering: 0.07800 (45%) | DB:
0.04700 (27%) | 200 OK
[http://localhost/search?query=come&forums%5B%5D=1]
A5dc4e45ad4d75e6a46cb2bbc8aa9e94?d=identicon&s=25 Vincent Tsao (vincentcao)
on 2006-08-21 08:34
hi you guys:
  i must add some extra infomation about my question before.
  i check the newest source code ,then install ferret ,rake migrate
(schema version:12 ),there are around 10 post(is not empty) in my forum.
  when i use the search function ,search the key words like 'come',will
search
nothing ,but there does have the keywords:'come'.
  i doubt if i fail to config the ferret or something else? does anyone
can tell what happen?
   Thanks
                                         vincent
3a83969376c805ef5b6042191fdb0ff3?d=identicon&s=25 Andreas S. (andreas)
on 2006-08-21 18:25
Vincent Tsao wrote:
> hi you guys:
>   i must add some extra infomation about my question before.
>   i check the newest source code ,then install ferret ,rake migrate
> (schema version:12 ),there are around 10 post(is not empty) in my forum.
>   when i use the search function ,search the key words like 'come',will
> search
> nothing ,but there does have the keywords:'come'.
>   i doubt if i fail to config the ferret or something else? does anyone
> can tell what happen?
>    Thanks
>                                          vincent

You can either
1) set :auto_index => true in app/models/post.rb
or
2) use scripts/update_index to update the index periodically.

The latter is recommended, especially if your forum has high traffic. Be
warned though that Ferret 0.9.5 is not very stable, so you might
experience some segfaults. I hope that these problems will be fixed in
the 0.10.0 version that is expected to be released soon.
A5dc4e45ad4d75e6a46cb2bbc8aa9e94?d=identicon&s=25 Vincent Tsao (vincentcao)
on 2006-08-21 18:55
I do try both your suggestions ,I'm afraid ,it still doesn't work, here
is my install ferret information:

C:\Documents and Settings\vincent>gem install ferret
Need to update 5 gems from http://gems.rubyforge.org
.....
complete
Building native extensions.  This could take a while...
ruby extconf.rb install ferret
creating Makefile

nmake

nmake install

nmake clean
Successfully installed ferret-0.9.5
Installing ri documentation for ferret-0.9.5...
Installing RDoc documentation for ferret-0.9.5...

 Maybe the ferret want to play a joke with me?  :)
 I wander if anyone face the same problem like mine
 Thanks
                         vincent
A5dc4e45ad4d75e6a46cb2bbc8aa9e94?d=identicon&s=25 Vincent Tsao (vincentcao)
on 2006-08-21 19:08
Hi Andreas Schwarz:
 I think I found what's the problem is:
 Do you remenber these tips in search template?

 "Search in: (hold the Control or Command key to select multiple
forums)"

 I search a key words like "demo" ,if i select multiple forums,then it
will
return nothing, but if i just select only one forums, it will return the
expect
result, i wonder if this situation is a bug of RForum or Ferret?
  thanks
                                            vincent
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.