Answer the question
In order to leave comments, you need to log in
How to write a request for the minimum price of child elements?
Given:
There is a table with houses. = houses
id, name
There is a table with flats = flats
id, house_id, price
You need to create two queries for the filter:
1. Filter houses by the price of apartments in ascending/descending order.
2. Find all the houses where the price of apartments starts from "from" or "to".
Ideal to understand how to do it on Eloquent if using Laravel
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question