# RE: Help with TextSearch :all and MySQL

**URL:** <https://www.ruby-forum.com/t/re-help-with-textsearch-all-and-mysql/94577>\
**Category:** Rails\
**Created:** [January 6, 2006, 8:12pm UTC](https://www.ruby-forum.com/t/re-help-with-textsearch-all-and-mysql/94577 "2006-01-06T20:12:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [January 6, 2006, 8:12pm UTC](https://www.ruby-forum.com/t/re-help-with-textsearch-all-and-mysql/94577/1 "2006-01-06T20:12:49Z")

</div>

Duane,

When I comment-out the ‘validate\_options’ lines in self.search, it  
works.

I’m relieved! 🙂

The ‘validate\_options’ should still be fixed. But at least it works with  
‘searches\_on :all’ or without it.

After the ‘validate\_options’ problem is solved, it would be good to  
please update the ‘search.rb’ code on the Rails wiki:

[Peak Obsession](http://wiki.rubyonrails.com/rails/pages/TextSearch)

Thank you very much for your help!

Matt

Wagner, Matt C. wrote:

> 

c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active\_record/bas  
e.rb:991:in

> ## `method_missing' #{RAILS_ROOT}/lib/search.rb:50:in `search’ #{RAILS\_ROOT}/app/controllers/foobar\_controller.rb:58:in `search’
> 
> The error is the same with or without ‘searches\_on :all’ in the model  
> file.
> 
> Where do you have ‘validate\_options’ defined?

–  
Matt C. Wagner  
Information Security Analyst

Network Intrusion Detection  
Security Operations Center  
Corporate Information Security  
Wells Fargo Bank

---

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [January 6, 2006, 11:19pm UTC](https://www.ruby-forum.com/t/re-help-with-textsearch-all-and-mysql/94577/2 "2006-01-06T23:19:17Z")

</div>

On Jan 6, 2006, at 12:09 PM, [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Wagner, Matt C. wrote:
> 
> > Where do you have ‘validate\_options’ defined?  
> > Hi Matt,

Thanks for your patience with this. I’m working from an older code  
base (Rails 0.13) and so there are some differences I didn’t expect.

It turns out that validate\_options is now part of the Hash class:  
[http://dev.rubyonrails.org/changeset/2167](http://dev.rubyonrails.org/changeset/2167)

So you should be able to replace that call with  
options.assert\_valid\_keys(:keys, :go, :here)

I’ll update the wiki. Thanks!

Duane J.  
(canadaduane)  
[http://blog.inquirylabs.com/](http://blog.inquirylabs.com/)
