Hey Jens,
Thanks for the reply.
When I try this 'work_phone' => { :index => :untokenized }, 'home_phone'
=> { :index => :untokenized } I get:
unknown stored parameter untokenized
C:/ruby/lib/ruby/gems/1.8/gems/ferret-0.9.6/lib/ferret/document/field.rb:221:in
`index='
C:/ruby/lib/ruby/gems/1.8/gems/ferret-0.9.6/lib/ferret/document/field.rb:182:in
`initialize'
#{RAILS_ROOT}/vendor/plugins/acts_as_ferret/lib/acts_as_ferret.rb:113:in
`work_phone_to_ferret'
#{RAILS_ROOT}/vendor/plugins/acts_as_ferret/lib/acts_as_ferret.rb:554:in
`to_doc'
#{RAILS_ROOT}/vendor/plugins/acts_as_ferret/lib/acts_as_ferret.rb:553:in
`to_doc'
#{RAILS_ROOT}/vendor/plugins/acts_as_ferret/lib/acts_as_ferret.rb:510:in
`ferret_update'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/callbacks.rb:333:in
`callback'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/callbacks.rb:330:in
`callback'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/callbacks.rb:268:in
`update_without_timestamps'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/timestamp.rb:48:in
`update'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/base.rb:1760:in
`create_or_update_without_callbacks'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/callbacks.rb:242:in
`create_or_update'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/base.rb:1523:in
`save_without_validation'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/validations.rb:744:in
`save_without_transactions'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/transactions.rb:120:in
`save'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb:51:in
`transaction'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/transactions.rb:86:in
`transaction'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/transactions.rb:112:in
`transaction'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/transactions.rb:120:in
`save'
#{RAILS_ROOT}/vendor/rails/activerecord/lib/active_record/base.rb:1570:in
`update_attributes'
#{RAILS_ROOT}/app/controllers/customers_controller.rb:23:in `update'
Jens Kraemer wrote:
> Hi!
> On Wed, Aug 30, 2006 at 05:29:58PM +0200, Michael Leung wrote:
>> not return any results if I query like 555-555-5555.
> Seems the tokenizer strips out the hyphens. This happens inside Ferret,
> after acts_as_ferret's debug message.
>
> use something like
>
> acts_as_ferret :fields => {
> :phone => { :index => :untokenized },
> ...other fields go here
> }
>
> to let Ferret store the phone numbers unchanged.
>
> Jens
>
>
> --
> webit! Gesellschaft f�r neue Medien mbH www.webit.de
> Dipl.-Wirtschaftsingenieur Jens Kr�mer [EMAIL PROTECTED]
> Schnorrstra�e 76 Tel +49 351 46766 0
> D-01069 Dresden Fax +49 351 46766 66
--
Posted via http://www.ruby-forum.com/.
_______________________________________________
Ferret-talk mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/ferret-talk