# Acts\_as\_ferret: experiencing bugs with very simple search

**URL:** <https://www.ruby-forum.com/t/acts-as-ferret-experiencing-bugs-with-very-simple-search/165461>\
**Category:** Ferret\
**Created:** [April 14, 2009, 6:25am UTC](https://www.ruby-forum.com/t/acts-as-ferret-experiencing-bugs-with-very-simple-search/165461 "2009-04-14T06:25:23Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![murfhy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/d26b3c/32.png) [@murfhy](https://www.ruby-forum.com/u/murfhy)\
**Post date:** [April 14, 2009, 6:25am UTC](https://www.ruby-forum.com/t/acts-as-ferret-experiencing-bugs-with-very-simple-search/165461/1 "2009-04-14T06:25:23Z")

</div>

I am doing a very simple search on my DB using acts\_as\_ferret. I put  
this in my “Venue” model:

acts\_as\_ferret :fields =\> [:name, :city]

And this is in my controller search action:

@t = Venue.find\_by\_contents(params[:search]+‘~’)

and then I just render the results.

render :text =\> @t.to\_json, :success =\> true, :status =\> :ok

If I run a quick test:

[http://localhost:3000/venue/list?search=The](http://localhost:3000/venue/list?search=The)

I see in my log that the proper query “The~” is being executed on the  
index. However, I get no results. I definitely have a few “Venues” with  
the word “The” in the name field.

Since this is a very simple search and acts\_as\_ferret is used quite a  
bit, I tried rebuilding the index to see if it was corrupted…no dice

Any ideas?

Thanks!
