last recode of db in laravel code example
Example 1: Last recode of DB using laravel
return DB::table('files')->order_by('upload_time', 'desc')->first();
Example 2: Last recode of DB using laravel
Model::latest()->first();
return DB::table('files')->order_by('upload_time', 'desc')->first();
Model::latest()->first();