I believe this is what you are looking for:
It can easily be achieved if you unpivot your data which is a good idea for the raw data you have if you want to create good visualization easily in a BI product like Qlik Sense:
RAWDATA: CROSSTABLE (Month,Sales) LOAD * INLINE [ Produits,jan,feb,mar,apr Apples sold,230,220,160,390 Apples soon to be sold,410,530,380,640 ]; DATA: LOAD Produits, // Convert the monthnames into real dates to get them sorted correctly Date#(Capitalize(Month) & ' 1 2017 ','MMM D YYYY') AS Date, Sales RESIDENT RAWDATA; DROP TABLE RAWDATA;
T.qvf 192.0 K
Thanks Petter for that first answer, which is very useful. kindly appreciated.
Now, my data are coming from 2 different documents on server.
Therefore, I need to use the functions LOAD & concatenate LOAD to get my data.
My real data are also looking like this: (but they are evolving. Therefore, I cannot write their values like in your answer)
apples sold 1 2 3 4 yes 230 220 160 390 no 410 530 380 640
From your solution, does that mean I need to write my program as such?
LOAD [apples sold], ,,,
concatenate LOAD [apples sold], ,,,
// Convert the monthnames into real dates to get them sorted correctly
Date#(Capitalize(Month) & '/2018 ','M/YYYY') AS Date,
DROP TABLE [RAWDATA];
My issue is that I got no values... in the graph...
Many thanks for your help again.