If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.
I have the data of accounts of income accounts, costs and expenses of a company.
I need to compare the monthly amount with the amount of the previous month.
I am importing the data from Excel and I have obtained the following results:
- When I use Date and quantity data, I get the comparison without problems (see Excel Hoja2)
Previous(Monto) AS MontoAnt,
(Monto-Previous(Monto)) AS VarMonto
(ooxml, embedded labels, table is Hoja1);
- When I add account IDs, I do not get the correct results (see Excel Hoja1)
(ooxml, embedded labels, table is Hoja2);
Could someone suggest me an alternative?
May be try this
If(IDCodigo = Previous(IDCodigo), Previous(Monto)) AS MontoAnt,
If(IDCodigo = Previous(IDCodigo), (Monto-Previous(Monto))) AS VarMonto
Order By IDCodigo, Fecha;
DROP Table Table;
View solution in original post