I have a database with lets assume two columns (service_date & invoice_amount). I would like to create an SQL query that would retrieve and group the data for each financial
to get data from April to March ---
SELECT
CASE
WHEN MONTH(application_receiving_date)>=4
THEN concat(YEAR(application_receiving_date), '-',YEAR(application_receiving_date)+1)
ELSE concat(YEAR(application_receiving_date)-1,'-', YEAR(application_receiving_date))
END AS app_year,
from table_name
GROUP BY app_year