Laravel: Sorting a column in the Left Join
<p>Lets say I have a simple table of users </p>

<p><code>id | userName
3    Michael
4    Mike
5    George</code></p>

<p>And another table of their cars and prices </p>

<p><code>id | belongsToUser | carPrice
1    4               5000
2    4               6000
3    4               8000</code></p>

<p>I would like to do a left join that would return the highest or lowest carPrice
At the moment, the query would return the last/first instance of that users carPrice.
I've tried entering the orderBy in various join queries but to no avail.</p>

<p>I have a helper function that would return the highest/lowest price on demand but I'm not sure how that would fit within this query as I would like to use laravels inbuilt paginate</p>