Yep.. it seems to be development mode related. Deployed and in production RAILS_ENV it works perfectly fine... strange...
On Dec 26, 3:55 pm, Pat Allan <[email protected]> wrote: > Hi Jörg > > The reason your post didn't appear straight away is because there's > moderation for everyone's first posts here (to avoid spam). Sorry for > the delay in getting it approved. > > As for your delta issue - it doesn't look like you're doing anything > wrong. Can you confirm you've restarted Sphinx (and re-indexed > inbetween stopping and starting) after adding the delta property? I'm > expecting you have though, which may mean the problem is how Sphinx > treats separate indexes. > > If the latter is the case, I can't offer much in the way of solutions, > except that I'm hoping to have a fix soon - Sphinx can merge indexes, > and so I want to get TS to a point where after running a delta index > it merges the results back into the core index (and so it gets treated > all as a single dataset again). > > Unfortunately, I'm not sure when I can get a solution done though (a > common statement of mine on this list, sadly). Hoping to have more > time to tackle TS improvements over the next month though. > > One other caveat - it takes Sphinx a second (maximum, although I guess > that would depend on local index sizes, etc) to catch up with the new > values in delta indexes - but I'm guessing there's a slight delay > between making your new instance and testing the search, so I doubt > that's the problem. > > Cheers > > -- > Pat > > On 26/12/2008, at 1:31 AM, Jörg Battermann wrote: > > > > > > > Hey there, > > > I am pretty sure I am doing something wrong, but for some reason new > > entries/instances of a model which has the delta-index declaration > > included do not show up in a generic, empty ("") search on that > > model... > > > The ts declaration is like that: > > > define_index do > > indexes title, :sortable => true > > indexes cached_plaintext_question, :as => :question > > indexes answers.cached_plaintext_body, :as => :answers > > indexes cached_tag_list, :as => :tags > > indexes user.name, :as => :user > > indexes answered_by, user_id > > > has created_at > > has answers(:id), :as => :answer_ids > > set_property :delta => true > > end > > > Now after creating a new new question (that's the model that's being > > indexed/searched), and going back to the controller's index, which has > > the following search code: > > > @search_options = { > > :page => (params[:page] || 1), > > :per_page => Question.per_page, > > :include => :user, > > :order => "created_at DESC", > > :match_mode => :extended > > } > > > @questions = Question.search((params[:search] || ""), @search_options) > > > .... @questions does not contain this new instance mentioned above, > > but does after a full (re-)index. > > > Why's that? > > > Cheers, thanks & merry x-mas to everyone :) > > -Jörg --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Thinking Sphinx" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/thinking-sphinx?hl=en -~----------~----~----~----~------~----~------~--~---
