9 Replies Latest reply: Jan 30, 2017 5:49 AM by Sunny Talwar RSS

    Date problem in Set Analysis - QLIK SENSE

    Senarath Bandara Herath

      Hi,

      I'm using below calendar in preparing a balance sheet in QLIKSENSE.

      Calander:

      load

        date(CAL_END_DATE) as CAL_END_DATE,

          YEAR(ADDMONTHS(CAL_END_DATE,-3)) AS Year,

           Date(YearEnd(CAL_END_DATE, 0, 4)) as FiscalDate,

          'Q' & CEIL(MONTH(AddMonths(CAL_END_DATE,-3))/3) AS Quarter,

        Month(CAL_END_DATE) as Month

       

      Resident Table;

       

      I'm using below two set analysis to display values for the

      01. Selected period and

      02. Beginning of current financial year as below.

       

      01. CURRENT YEAR

      Sum({$<FiscalDate=,CAL_END_DATE={'=Date(FiscalDate)'}>}YTD)

       

      02.YEAR BEGINNING

      Beginning of current financial year ( OR end of last financial year)

      Sum({$<FiscalDate=,CAL_END_DATE={'=Date(AddYears(FiscalDate,-1))'}>}YTD)

       

      My problem is I'm getting the SAME value that I get for the current year for the year beginning as well.

       

      Any expert advice please.

       

      Thanks

      Senarath