How to get the total amount in a database table field month wise of the current year using laravel – Phpmyadmin
So I have database with amount and created_at field on it and I want to the total amount per month of the current year and or every year. $sql = 'SELECT SUM(amount) as "Amount",MONTHNAME(created_at) as "Month" FROM transactions WHERE YEAR(created_at)…