I am new to laravel. I'm working on this laravel 5 app but got stuck on trying to perform a query like below.
select * from carts inner join users on carts.manager_id = users.id
where cart_num like "e%" OR name like "e%"
having region = (select region from users where id = 3);
Edit
The aim of the query is to get the carts of managers in the same region as an administrator (hence reason for the subselect. id is the id of the administrator)
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire