Hi Andrew
This is actually the expected behaviour - though it definitely needs some
documentation love. Boolean, integer and timestamp attributes can all be
updated in the original index, so the delta is not needed in these situations.
I'm guessing in your situation it means that the WHERE clause isn't coming into
effect. I should add a setting to disable these 'smarter' updates - but in the
meantime, I guess a work-around is:
has "reviewed", :type => :boolean
Using a string implies a SQL snippet, and TS can't/won't try to figure out what
column(s) the string references, and so will perform a delta update in all
situations.
Hope this adds some clarity to the situation.
Cheers
--
Pat
On 02/03/2010, at 2:15 AM, Andrew Stewart wrote:
> Hello,
>
> I have a model with a boolean column ("reviewed"). In my define_index
> block I list it as an attribute and exclude it in a where clause. My
> problem is that when only this column is updated, Thinking Sphinx
> doesn't add the record to the delta index. However when I update a
> field, e.g. "event", the record is added to the delta index as
> expected.
>
> This is what my index block looks like:
>
> define_index do
> indexes event
> has reviewed
> where 'reviewed = 0'
> set_property :delta => true
> end
>
> Please could you tell me how to get records added to the delta index
> when their boolean attribute is updated?
>
> I see this in both Passenger (development) and Mongrel (production).
> I'm using Thinking Sphinx 1.3.16, Riddle 1.0.10, and Sphinx 0.9.8-rc2
> (r1234).
>
> Thanks in advance,
>
> Andy Stewart
> ------
> http://airbladesoftware.com
>
> --
> 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.
>
--
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.