RisteDimitrievski
Active member
So when i run query via finder method
It will output 1 users that are in that secondary group, i noticed that when that secondary group id i'm searching is in first place it can be retrieved, otherwise no. But when i run query
Note LIKE operator only returns 1 result from the table.
I get all members from that group. Any idea how to solve it from finder ? without needing to put custom query as will break current pagination
PHP:
$user->whereOr(['user_group_id','=',$groupid],['secondary_group_ids','LIKE',$groupid])->limitByPage($page,$perPage)->fetch()->toArray();
Note LIKE operator only returns 1 result from the table.
PHP:
SELECT * FROM `xf_user` WHERE `user_group_id` = 4 OR `secondary_group_ids` RLIKE 4