I have a table with MySQL in the following fields: Date, Value, Type.
You can type either export or import. I need a question which gives trade deficit (export-import) for every month Is this possible with a single question?
You should store your date as year / month / day different columns, or easily Any method of linking to a table that lets you do it, otherwise you have to calculate slower on every date
column to work over a month, I will leave it as if you have it so far But I will suggest different dates to make this calculation easy ( If you group only for one month, then an additional column that stores the result of EXTRACT (YEAR_MONTH)
(I have not tested this, and can be a syntax mix, but this should work)
Comments
Post a Comment