Oups... my mistake.
:group_clause => "@geodist asc" works as expected.... I guess that
Sphix takes the first result in every group, this group being sorted
by order and takes this as a reference when accessing an internal
attribute for sorting the group.

Thanks

On Aug 3, 10:27 pm, Pierre Valade <[email protected]> wrote:
> Sorry, but in fact the :group_clause => "@geodist asc" doesn't work...
> (which is logic)...
>
> My situation is that I search in a table Publications that can have a
> lot of same place_id
>
> And I want to order the Publications using geodist and having only one
> publication per place_id
>
> Thanks,
> Pierre
>
> On Aug 3, 10:20 pm, Pierre Valade <[email protected]> wrote:
>
> > Pat,
>
> > I've checked the documentation.
>
> > I have provided a :group_clause => "@geodist asc" option and things
> > are great.
>
> > I don't know what Sphinx takes as the @geodist for a whole group but
> > it seems to work fine.
>
> > Pierre
>
> > On Aug 3, 10:13 pm, Pierre Valade <[email protected]> wrote:
>
> > > Hi Pat,
>
> > > I've tried to group the results.
>
> > > But I want to use it with :geo options and :sort "@geodist asc" and
> > > the results, when using :group, are not sorted anymore.
>
> > > On Aug 3, 9:52 pm, Pat Allan <[email protected]> wrote:
>
> > > > You shouldn't be getting multiple instances of the same record back in  
> > > > a search... unless you're using STI, as that's still not perfect yet.
>
> > > > If you want to ensure one record for each value of a given attribute,  
> > > > then you'll need to group the 
> > > > results.http://freelancing-god.github.com/ts/en/searching.html(seethelast 
> > > > section)
>
> > > > --
> > > > Pat
>
> > > > On 03/08/2009, at 8:15 PM, Pierre Valade wrote:
>
> > > > > Hello,
>
> > > > > Is there a way to select only distinct results from a Sphinx search,
> > > > > as that is possible with mysql ?
>
> > > > > Thanks,
> > > > > Pierre
--~--~---------~--~----~------------~-------~--~----~
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