Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

amiyo_ghosh's avatar

Complex Scope Query

Hello All i want to use user id of wherehas query in the second method. how can i achieve this? Thanks in advance Image

Edit : memeber is a typo.. it will be agent. i have on table agent_to_manager and i want to fetch only agent roled users that is not present in agent_to_manager table.. and i have two queries one that fetch only agent role user and second checks where the fetched users are not present in agent_to_manager table.. but i wont able to get the whereHas query's result to run the second query

0 likes
1 reply
amiyo_ghosh's avatar

BUMP PLEASE SOMEONE HELP ME!!!!!!!!!!!!!!!!!!!!!!!!

Please or to participate in this conversation.