Rake adds a link method at a global level to Ruby, which is really frustrating. 
Try the following:

  indexes assoc(:link).title, :as => :link_title

Cheers

-- 
Pat

On 11/09/2012, at 11:40 PM, soheildb wrote:

> I have the following define_index method:
>   
> define_index do
>     indexes content
>     indexes tags.content, :as => :tag_content
>     indexes link.title
> 
>     has :is_private
>     has :user_id
>     has :created_at
>   end
> 
> When I index I get the following error:
> WARNING: Global access to Rake DSL methods is deprecated.  Please include
>     ...  Rake::DSL into classes and modules which use the Rake DSL methods.
> WARNING: DSL method ThinkingSphinx::Index::Builder#link called at 
> /Users/azamtaghipoor/pakrat/Pakrat/app/models/user_post.rb:64:in `block in 
> <class:UserPost>'
> rake aborted!
> wrong number of arguments (1 for 2)
> 
> I've already tried :link, :link:title :link.title and similar variations
> 
> without the indexes link.title all works fine.
> Any help would be much appreciated
> Thanks,
> Soheil
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Thinking Sphinx" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/thinking-sphinx/-/FZp80UO-FPQJ.
> 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.

Reply via email to