I'm making the below query:
SELECT
`user_organisation`.*,
`users`.`full_name`,
`users`.`email`,
`users`.`avatar`
FROM
`user_organisation`
INNER JOIN `users` ON `users`.`id` = `user_organisation`.`user_id`
WHERE
`users`.`full_name` LIKE '%test%' OR `users`.`email` LIKE '%test%' AND `user_organisation`.`organisation_id` = 111
And I get the results containing user_organisation.organisation_id equals 111 and 222. I want to search records with users.full_name or users.email containing value test. This SQL successfully searches users with full name or email containing string test but not only user_organisation.organisation_id=111.
What the reason for that unexpected behaviour? I sure I'm missing something but I can't see...