Pat,

Some more investigation on this...........i commented out each of the
relationships until i and it looks like this line is the culprit,

has product_types(:id), :as => :product_type_ids

the relationship is a has_many :through like the others but for this
particular form i only allow the user to select one product type not
multiple.  Not sure why this would make a difference anyway so i need
to look into that.

So just to clarify, it is working fine with or without my
relationships, its just that one instance above,

Thanks for your help,

JB
On 6 Apr, 11:50, johnnybutler7 <[email protected]> wrote:
> Pat,
>
> Thanks for responding, im picking this up again.  It doesn't work if i
> create a product with or without any or all the associations.
>
> Im a bit stuck on this,
>
> JB
>
> On 2 Apr, 06:37, Pat Allan <[email protected]> wrote:
>
>
>
> > Hi JB
>
> > This sounds like some issues that were being hit with deltas a while ago, 
> > but I was quite sure they're fixed. When you're creating a new Product 
> > without any of the association objects (so - categories.collect(&:id) is 
> > [], etc), does it work? What happens if you create a new Product that has 
> > at least one of each of the associations?
>
> > Cheers
>
> > --
> > Pat
>
> > On 02/04/2010, at 2:08 AM, johnnybutler7 wrote:
>
> > > Hi,
>
> > > I have a model called Product with the following index:
>
> > > define_index do
> > >    indexes :desc
> > >    indexes :name
> > >    indexes :meta_keywords
> > >    indexes :meta_desc
>
> > > has :product_status_id, :variant_type_id, :manufacturer_id, :base_price, 
> > > :created_at, :rating_score, :sold_serial_numbers_count, :views_count
> > >    has categories(:id), :as => :category_ids
> > >    has operating_systems(:id), :as => :operating_system_ids
> > >    has host_applications(:id), :as => :host_application_ids
> > >    has product_types(:id), :as => :product_type_ids
>
> > >    set_property :delta => :delayed
> > >  end
>
> > > If i comment out the associations below delayed job indexes the new
> > > fields as expected but when i include them delayed job does nothing.
>
> > > has categories(:id), :as => :category_ids
> > > has operating_systems(:id), :as => :operating_system_ids
> > > has host_applications(:id), :as => :host_application_ids
> > > has product_types(:id), :as => :product_type_ids
>
> > > I cant find anything specific in the group regarding this, one or two
> > > people mentioning it but no fix.  Can anyone explain why its happening
> > > and if there is a fix for it.
>
> > > I have the following setup:
> > > Thinking Sphinx Gem 1.3.16
> > > TS delayed delta 1.0.4
> > > rails 2.3.2
> > > postgres 8.4
>
> > > JB
>
> > > --
> > > 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 
> > > athttp://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.

Reply via email to