<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Script help in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Script-help/m-p/624002#M229645</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try the attached.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 11 Mar 2014 12:33:50 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-03-11T12:33:50Z</dc:date>
    <item>
      <title>Script help</title>
      <link>https://community.qlik.com/t5/QlikView/Script-help/m-p/623997#M229640</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am working on Attendance Tracking system.&lt;/P&gt;&lt;P&gt;And want to find such employees who are Absent for 7 or more consecutive days.(Working days)&lt;/P&gt;&lt;P&gt;I have the following fields in it.&lt;/P&gt;&lt;P&gt;Empid,Date,Status&lt;/P&gt;&lt;P&gt;Status has the values as Present,Absent.Off&lt;/P&gt;&lt;P&gt;How do I proceed to get a solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards,&lt;/P&gt;&lt;P&gt;Priya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 11:46:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Script-help/m-p/623997#M229640</guid>
      <dc:creator />
      <dc:date>2014-03-11T11:46:38Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.qlik.com/t5/QlikView/Script-help/m-p/623998#M229641</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you upload some sample data.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 11:52:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Script-help/m-p/623998#M229641</guid>
      <dc:creator>jsingh71</dc:creator>
      <dc:date>2014-03-11T11:52:49Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.qlik.com/t5/QlikView/Script-help/m-p/623999#M229642</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you load your sample data file?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 11:54:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Script-help/m-p/623999#M229642</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2014-03-11T11:54:25Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.qlik.com/t5/QlikView/Script-help/m-p/624000#M229643</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls Find the sample data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Priya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 12:06:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Script-help/m-p/624000#M229643</guid>
      <dc:creator />
      <dc:date>2014-03-11T12:06:47Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.qlik.com/t5/QlikView/Script-help/m-p/624001#M229644</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You need something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Load your existing data:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Data1:&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;LOAD EmpID, &lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; Date,&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; Status,&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; ...&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;FROM .....;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now load from the Data resident&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Data2:&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;LOAD *,&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt; &lt;/SPAN&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; If(EmpID = Previous(EmpID), &lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; If(Previous(Status) = 'Absent' And Status = 'Absent', &lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; Peek('ConsecutiveAbsentDays') + 1,&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; If(Status = 'Absent', 1, 0)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; ),&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; If(Status = 'Absent', 1, 0)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp; ) As ConsecutiveAbsentDays&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Resident Data1&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;ORDER BY EmpID, Date;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Finally drop the first Data table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;DROP Table Data1;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now you can create an straight table object with Dimension &lt;EM&gt;EmpID&lt;/EM&gt; and expression &lt;EM&gt;If(Max(ConsecutiveAbsentDays) &amp;gt;= 7, 'Absent &amp;gt; 7 Days') &lt;/EM&gt;and ensure that suppress 0 and suppress missing options are on&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 12:15:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Script-help/m-p/624001#M229644</guid>
      <dc:creator>jonathandienst</dc:creator>
      <dc:date>2014-03-11T12:15:15Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.qlik.com/t5/QlikView/Script-help/m-p/624002#M229645</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try the attached.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Mar 2014 12:33:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Script-help/m-p/624002#M229645</guid>
      <dc:creator />
      <dc:date>2014-03-11T12:33:50Z</dc:date>
    </item>
  </channel>
</rss>

