select * from school where 'id' in (select state from student where user_id=$student_id) 를 적용하고 싶습니다.
쿼리빌더로 구현을 원하시는지 엘로퀀트 ORM으로 구현을 원하시는지 모르겠지만
엘로퀀트라면 아래를 참고해주시고
https://stackoverflow.com/questions/35724771/laravel-eloquent-orm-where-in-subquery
쿼리빌더라면 아래를 참고해주세요.
https://laravel.kr/docs/5.5/queries#raw-expressions
select * from school where 'id' in (select state from student where user_id=$student_id) 를 적용하고 싶습니다.