skip to Main Content

Laravel – groupby sum and count tickets

I am learning to use groupBy. In my exercise, I must count the number of tickets that were sold and add the total money collected. $tickets = Ingresostaquilla::groupBy('tipo') ->selectRaw('count(*) as quantity, tipo') ->get(); I did the count by type of…

VIEW QUESTION
Back To Top
Search