mercredi 11 septembre 2019

How to Marge This Query in One In laravel 5.8

$report = Reporting::where('board_id',$id)->where('status','income') ->select(DB::raw('SUM(payment) as total_expense, MONTH(date) as month, YEAR(date) as year')) ->groupby('year','month') ->get();

$reports = Reporting::where('board_id',$id)->where('status','expense') ->select(DB::raw('SUM(payment) as total_expense, MONTH(date) as month, YEAR(date) as year')) ->groupby('year','month') ->get();



from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/2NWTQkS
via IFTTT

Aucun commentaire:

Enregistrer un commentaire