sql order by asc laravel code example
Example 1: order By Asc in laravbel
->orderBy('id', 'DESC');
Example 2: laravel order by raw
$orders = DB::table('orders')
->orderByRaw('updated_at - created_at DESC')
->get();