3 Replies Latest reply: Nov 5, 2015 3:38 PM by Ana Aparicio RSS

    How to compare this year and last year's sales data

      Hi,

      I am trying to do an expression to compare this year vs last year's sales data. Below is the formula that I am using. It showuld say in percentage.

      =IF(MONTH(INVOICEDATE) > MONTH(TODAY()), 0, (SUM(IF(YEAR(INVOICEDATE) = YEAR(TODAY()), INVOICEAMOUNT, 0))/ SUM(IF(YEAR(INVOICEDATE) = YEAR(TODAY())-1, INVOICEAMOUNT, 0))) -1).

      But, it is showing 0 for everything. Can anyone please assist me on this?