Problem with searching for floats

Hello. I'm not sure if I found a bug. I'm trying to search for price ranges (my price column is a float):

Entry.search(:with => {:price => 5})

When I do that, I get this error:

ThinkingSphinx::SphinxError: index entry_core: unsupported filter type 'intvalues' on float column

Is this a potential bug in FlyingSphinx?

  1. If price is a float, then you need to use floats in the filters - Sphinx is pretty fussy about that. So try:

    Entry.search(:with => {:price => 5.0})
    
  2. Hi Pat. I tried it with floats in the filters too like you mentioned:

    Entry.search(:with => {:price => 5.0})

    I'm still getting the same error

    ThinkingSphinx::SphinxError: index entry_core: unsupported filter type 'intvalues' on float column

    Do you think it might be a Heroku server issue instead (i.e. Heroku's Sphinx can't filter floats)?

  3. I run the servers with Sphinx, not Heroku - the Heroku apps just talk to my servers :)

    What's your app name? And the define_index block on your Entry model? Feel free to make this conversation private if you'd prefer.

  4. Oh okay, no problem at all. I think it might be my code so I'll test things and post my findings here. Really appreciate you help and the great plugin, btw!

  5. No worries. One place to start is does it work locally for you? :)

  6. Pat Allan closed this discussion on 12 May, 2011 02:21 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac

Recent Discussions