Questions tagged [thinking-sphinx]

Thinking Sphinx is a Ruby library that connects ActiveRecord models to the Sphinx search service.

Thinking Sphinx is a Ruby library that connects ActiveRecord models to the Sphinx search service.

Sphinx is a very fast search engine that indexes data and provides flexible ways of searching it. Thinking Sphinx allows you to link up your models into Sphinx simply and painlessly, and provides an interpretation of search results into ActiveRecord model instances.

875 questions
4
votes
3 answers

Accent Insensitive ordering in Sphinx

I am using Sphinx with the Thinking Sphinx plugin to search my data. I am using MySQL. My data contains accented chars ("á", "é", "ã") and I want them to be equivalent to their non-accented counterparts ("a", "e", "a", for example) when searching…
user104397
3
votes
2 answers

How to search @ | & ( ) in sphinx

How to search @ | & ( ) in sphinx. I want the results contains these symbols, it is keyword for sphinx, how should I search these stuff? thanks
dexterdeng
  • 249
  • 3
  • 13
3
votes
1 answer

Add column without down time

I need to add thinking-sphinx delta column in my table that is having 17Million records, then i need to index that field. The DB is postgres and adding the column will be resulted in a down time for an hour which is not bare-able, so any…
Gul
  • 1,757
  • 2
  • 15
  • 26
3
votes
1 answer

Sphinx Daemon returned error: index product_core: INTERNAL ERROR: incoming-schema mismatch. Only on staging server

The application is using Rails 2.3.12 and ThinkingSphinx 1.4.11 . There is only one index on Product model and it is working OK on devel box. After cap staging deploy I am generating config on the server, creating index, and starting daemon: bundle…
Casual Coder
  • 1,492
  • 2
  • 14
  • 15
3
votes
1 answer

mismatch of schema in thinking sphinx

I'm working with thinking sphinx define_index do indexes to indexes created_on has created_on end now while searching on console Emaildumps.search 5.day.ago, :group_by => 'created_on', :group_function =>…
3
votes
1 answer

Thinking Sphinx - Errors out when i try to reindex?

Ok so i have a rails application on our server and I have thinking shinx installed. Every day at 12:30am I run a cron job that truncates the account and contact tables and reinserts them...here is my crons 30 0 * * * /bin/bash -l -c 'cd…
Matt Elhotiby
  • 43,028
  • 85
  • 218
  • 321
3
votes
1 answer

Thinking Sphinx Delta Index not working

I have added the delta column to my table: class AddDeltaIndexToCimgs < ActiveRecord::Migration def change add_column :cimgs, :delta, :boolean, default: true, null: false end end I migrated I also added the define_index: define_index do …
Zequez
  • 3,399
  • 2
  • 31
  • 42
3
votes
1 answer

ThinkingSphinx Polymorphic relation problem | rails 3.1

I could not create index with thinking_sphinx for the simple polymorphic schema below. (Note: I am able to create index from has_many models but I want to create my indexes from 'belongs_to' model (Comment).) For simplicity, I created a sample…
3
votes
1 answer

Searching through a collection of indexed model objects using Thinking Sphinx

I have a Technique model which belongs_to User and is indexed by Thinking Sphinx. I also have a method in my model that returns an array of Technique objects: def possible_children(user) user.techniques - (self.children + [self]) end This…
Mitya
  • 1,013
  • 8
  • 14
3
votes
1 answer

simple OR search with attributes in thinking-sphinx?

Is it possible to perform a simple "OR" search in thinking-sphinx? here is a small example in pseudocode. define_index do ... has :attr_a, :attr_b end Object.search @q, :conditions => {...some cond...}, :with => {:attr_a => value_a OR :attr_b…
Silab
  • 31
  • 2
3
votes
2 answers

Defining indexes for associated models with Thinking Sphinx

What is the proper way of defining indexes on associated models with following configuration? I have model Locality with lat and lng attributes and associated models Profile and User class User < ActiveRecord::Base has_one :user_profile …
Igor Pavelek
  • 1,444
  • 14
  • 22
3
votes
1 answer

Difference between Thinking Sphinx indexing methods

Wondering what is the difference between these: indexes shop.created_at, :as =>created_at has shop(:created_at), :as => :created_at has shop.created_at, :as => :created_at Thanks.
Victor
  • 13,010
  • 18
  • 83
  • 146
3
votes
1 answer

Using Thinking Sphinx and staying DRY (Don't Repeat Yourself)

In the large project I'm working on we have many models we want to index and search. I'm finding myself repeating things over and over... and know this could be bad later when we make changes! Is there a good way to keep code DRY while using…
Jason
  • 11,709
  • 9
  • 66
  • 82
3
votes
1 answer

What does the error "ERROR: index ‘product’: raw_hits: write error: 122070 of 262017 bytes written" mean in Sphinx?

Some of my indexes appear to be failing during the nightly rebuild with this error: ERROR: index ‘product’: raw_hits: write error: 122070 of 262017 bytes written The only reference I can find on the internet is in some multibyte language that I…
RubyRedGrapefruit
  • 12,066
  • 16
  • 92
  • 193
3
votes
1 answer

Thinking Sphinx not indexing certain models

This is quite strange. I have 3 models (A, B, C). Were working perfectly when crontab runs it. Recently, I was having problem with indexing new entries for model A. When I invoke rake ts:index RAILS_ENV=production manually, indexing runs fine. No…
Victor
  • 13,010
  • 18
  • 83
  • 146