1 Reply Latest reply: Sep 5, 2017 11:04 AM by Jayesh Mule RSS

    CrossTable loads data twice in the Qlikview / Sense

    Jayesh Mule

      Below is the script which I am loading with some modification on data from SQL Server. But the data is loaded twice in Qlikview or Qliksense. Please guide on this.




      CrossTable([DateCol], [DefectState], 22)



      [ReleaseID] AS [ReleaseId],

      [Application] AS [Defects.Application],





      Date(LEFT([CreatedDate], 10)) as [CreatedDate],

          Date(MonthStart([CreatedDate]), 'MMM-YYYY') as DefectCreatedMonthYear,

          Date(Left([CreatedDate],10), 'DD-MMM') as DefectCreatedMonthDay,

      Date(LEFT([CloseDate], 10)) as [CloseDate],

          Date(MonthStart([CloseDate]), 'MMM-YYYY') as DefectClosedMonthYear,

          Date(Left([CloseDate],10), 'DD-MMM') as DefectClosedMonthDay,






          Interval( if(IsNull([CloseDate]), Today(), [CloseDate])  - [CreatedDate], 'd') AS [DefectAging],





      Interval(if (IsNull([CloseDate]), Today(), [CloseDate]) - CreatedDate, 'd') <= 3,

      '<=3 days',


      Interval(if (IsNull([CloseDate]), Today(), [CloseDate]) - CreatedDate, 'd') <= 6,

      '>3<=6 days',


      Interval(if (IsNull([CloseDate]), Today(), [CloseDate]) - CreatedDate, 'd') <= 10,

      '>6<=10 days',

      '>10 days'



      ) AS AgingCategory,



          Date(MonthStart([CreatedDate]), 'MMM-YYYY') as DefectCreated,

      Date(MonthStart([CloseDate]), 'MMM-YYYY') as DefectClosed;

      SQL SELECT *

      FROM Defects;



      Please help data is loading twice with this statement.