Hi Jonathan

I've just reviewed the code, and you're correct - the documented behaviour does 
not work. If shifting those options into the definition arguments works for 
you, fantastic.

The more I think about it, the more I think those settings don't belong in an 
index definition anyway - they're only relevant for searching. I'm not yet sure 
where they *should* go though. I'll keep mulling it over.

-- 
Pat

On 08/08/2013, at 3:18 AM, Jonathan del Strother wrote:

> Hi there,
> 
> This page suggests using "set_property :field_weights" in your index 
> definitions http://pat.github.io/thinking-sphinx/searching.html .   Correct 
> me if I'm wrong, but it seems like in TS3, nothing inside the index 
> definition block is executed unless you're generating the configuration file. 
>  So default field weights set this way don't have any effect.
> 
> I was able to get it working by moving the field_weights setting to the top 
> of the index file, like this : 
> 
> ThinkingSphinx::Index.define :user, :field_weights=>{username: 2} do
>   ...
> end
> 
> 
> I just wanted to check that was the correct way of doing things in TS3, and 
> that there wasn't something completely borked with my setup that's causing 
> set_properties to have no effect.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Thinking Sphinx" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/thinking-sphinx.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Thinking Sphinx" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/thinking-sphinx.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to