Open caseyhoward opened 14 years ago
Let's say I have a model User that has and belongs to many Teams. We also have one user with id 1 who has two teams with id's 1 and 2.
> User.teams_id_is_any(1,2) => [ <User id: 1>, <User id: 1> ]
I think this happens because searchlogic uses the :joins option instead of :include. I know that is done as an optimization, but if I get bad results it doesn't really help me. Can there be some sort of option to use :include instead of :joins?
Same here, I had to call uniq on the array
Let's say I have a model User that has and belongs to many Teams. We also have one user with id 1 who has two teams with id's 1 and 2.
I think this happens because searchlogic uses the :joins option instead of :include. I know that is done as an optimization, but if I get bad results it doesn't really help me. Can there be some sort of option to use :include instead of :joins?