order by sum() laravel
snippet in php

order by sum() laravel

user9855

Auth::user()->orderByRaw('SUM(points) DESC')->get();