Community Discussion
How to properly optimize Eloquent eager loading with subquery constraints in Laravel 11?
Asked by Rajivv Sharma ¡¤ 3 weeks ago
I have a `Course` model that has many `Modules`, which in turn have many `Lessons`. I want to fetch all published courses along with only the lessons that have `is_free_preview = true`, while also calculating the total count of all lessons without doing N+1 queries. What is the most idiomatic Laravel 11
15 views
2 answers
Answers (2)
Accepted Answer
sdffssfff
Answered by Rajivv Sharma ¡¤ 3 weeks ago
Accepted Answer
sdf sf sfs sfsfs
Answered by Rajivv Sharma ¡¤ 3 weeks ago
Your Answer
You must log in to answer this question.
Login to Answer