The difference between sphinx thinking indexing methods

I wonder what the difference between the two is:

indexes shop.created_at, :as =>created_at
has shop(:created_at), :as => :created_at
has shop.created_at, :as => :created_at

Thank.

+3
source share
1 answer

So, I don’t think that there is a difference between the 2nd and 3rd (believe me if I am wrong!), However I am sure of the difference between the 1st and 2nd

indexes used to indicate the field - on the Thinking Sphinx website:

Fields are the content for your searches - so if you want words to be attached to a specific document, you need to make sure theyre in the field of your index. They are just string data - you can have numbers and dates, etc. In your fields, but Sphinx will only consider them as strings, and nothing more.

has used to indicate an attribute - again, according to the Thinking Sphinx website:

, . Sphinx , theyre : , , datetimes ( Unix - , , ), . , , , .

+7

Source: https://habr.com/ru/post/1785596/


All Articles