<?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 Create calendar table that defines pay schedule in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295932#M109800</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; What could be wrong:&lt;BR /&gt; - Check your variable - what it shows if you put it in a text box?&lt;BR /&gt; - Make sure your Date field is the integer date, not a timestamp.&amp;nbsp; If you're not sure, add floor() function:&lt;BR /&gt;if(mod(&lt;STRONG&gt;floor&lt;/STRONG&gt;(Date)-'$(D)',14)=0,Date)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 20 Feb 2012 12:18:57 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2012-02-20T12:18:57Z</dc:date>
    <item>
      <title>Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295927#M109795</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is there a way to create a calendar table that defines the pay schedule? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We get paid every 2 weeks, but the specific pay date is not recorded in our system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So say today is the day everyone gets their check. Today's Check (02/17/2012) includes the dates 01/30/2012 - 02/12/2012&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to create a master calendar that I can tie into ours time ticket table that will allow me to group the correct dates into each pay schedule. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is something like this possible?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Feb 2012 16:05:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295927#M109795</guid>
      <dc:creator />
      <dc:date>2012-02-17T16:05:25Z</dc:date>
    </item>
    <item>
      <title>Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295928#M109796</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here as a possible solution.&lt;/P&gt;&lt;P&gt;First, take a known payday, and store it in a variable, for example:&lt;/P&gt;&lt;P&gt;LET D = makedate(2012,2,17);&lt;/P&gt;&lt;P&gt;Next, in your master calendar, add a flag, so PayDay=1 means it is a payday&lt;/P&gt;&lt;P&gt;if(mod(Date-'$(D)',14)=0,1,0) as PayDay&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Feb 2012 18:00:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295928#M109796</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-02-17T18:00:43Z</dc:date>
    </item>
    <item>
      <title>Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295929#M109797</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This would be close, but would it be possible to list the date for the scheduled pay with each date?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Say instead of having a flag just for the 17th,&amp;nbsp; the dates from 01/30/2012-02/12/2012 would have a corresponding field that has the value 02/17/2012?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Feb 2012 19:04:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295929#M109797</guid>
      <dc:creator />
      <dc:date>2012-02-17T19:04:07Z</dc:date>
    </item>
    <item>
      <title>Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295930#M109798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Sure, it is the same:&lt;/P&gt;&lt;P&gt;if(mod(Date-'$(D)',14)=0,Date) as PayDay&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Feb 2012 19:07:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295930#M109798</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-02-17T19:07:49Z</dc:date>
    </item>
    <item>
      <title>Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295931#M109799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I tried this expression and it does not return anything, just - for missing or null&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 12:05:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295931#M109799</guid>
      <dc:creator />
      <dc:date>2012-02-20T12:05:58Z</dc:date>
    </item>
    <item>
      <title>Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295932#M109800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; What could be wrong:&lt;BR /&gt; - Check your variable - what it shows if you put it in a text box?&lt;BR /&gt; - Make sure your Date field is the integer date, not a timestamp.&amp;nbsp; If you're not sure, add floor() function:&lt;BR /&gt;if(mod(&lt;STRONG&gt;floor&lt;/STRONG&gt;(Date)-'$(D)',14)=0,Date)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 12:18:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295932#M109800</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-02-20T12:18:57Z</dc:date>
    </item>
    <item>
      <title>Re: Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295933#M109801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When the variable is placed in a text box it returns this: 6.2189054726368e-005 which when the Date function is applied returns this: 12/30/1899&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Nevermind I forgot to change the variable to the one I used in the expression.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Still this is doing the same thing as the flag. On the actual pay day it displays the date. So say for the date 02/17/2012 it displays 02/17/2012.&lt;/P&gt;&lt;P&gt;I need it to display 02/17/2012 for all the dates between 01/30/2012 and 02/12/2012. 02/17/2012 should display the pay date 03/02/2012.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 12:51:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295933#M109801</guid>
      <dc:creator />
      <dc:date>2012-02-20T12:51:08Z</dc:date>
    </item>
    <item>
      <title>Re: Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295934#M109802</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; How you stored the 01/30/2012 - 02/12/2012 in table?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I mean whole thing in single field or stored as from and to?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Celambarasan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 13:01:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295934#M109802</guid>
      <dc:creator>CELAMBARASAN</dc:creator>
      <dc:date>2012-02-20T13:01:35Z</dc:date>
    </item>
    <item>
      <title>Re: Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295935#M109803</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is a single field that is recorded for the time ticket date. There is no reference on the record for when the actual pay date is.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 13:02:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295935#M109803</guid>
      <dc:creator />
      <dc:date>2012-02-20T13:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295936#M109804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Can you attach a sample data?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Celambarasan&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 13:30:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295936#M109804</guid>
      <dc:creator>CELAMBARASAN</dc:creator>
      <dc:date>2012-02-20T13:30:50Z</dc:date>
    </item>
    <item>
      <title>Re: Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295937#M109805</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here is the calendar code I am using:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code"&gt;&lt;P&gt;Calendar:&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET vDateMin = Num(MakeDate(2010,1,1));&amp;nbsp; &lt;/P&gt;&lt;P&gt;LET vDateMax = Floor(MonthEnd(Today()));&amp;nbsp; &lt;/P&gt;&lt;P&gt;LET vDateToday = Num(Today());&amp;nbsp; &lt;/P&gt;&lt;P&gt;LET PD = Date(makedate(2010,1,08));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TempCalendar:&amp;nbsp; &lt;/P&gt;&lt;P&gt;Left Keep (PayCore)&lt;/P&gt;&lt;P&gt;LOAD &lt;/P&gt;&lt;P&gt;$(vDateMin) + RowNo() - 1 AS DateNumber,&amp;nbsp; &lt;/P&gt;&lt;P&gt;Date($(vDateMin) + RowNo() - 1) AS TempDate&amp;nbsp; &lt;/P&gt;&lt;P&gt;AUTOGENERATE 1&amp;nbsp; &lt;/P&gt;&lt;P&gt;WHILE $(vDateMin)+IterNo()-1&amp;lt;= $(vDateMax);&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Calendar:&amp;nbsp; &lt;/P&gt;&lt;P&gt;LOAD &lt;/P&gt;&lt;P&gt;Date(TempDate) AS CalendarDate,&amp;nbsp; &lt;/P&gt;&lt;P&gt;Date(TempDate) AS&amp;nbsp; calendarlink,&lt;/P&gt;&lt;P&gt;if(mod(floor(TempDate)-'$(PD)',14)=0,TempDate) as PayDay,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// Standard Date Objects&lt;/P&gt;&lt;P&gt;Day(TempDate) AS CalendarDayOfMonth,&amp;nbsp; &lt;/P&gt;&lt;P&gt;WeekDay(TempDate) AS CalendarDayName,&amp;nbsp; &lt;/P&gt;&lt;P&gt;Week(TempDate) AS CalendarWeekOfYear,&amp;nbsp; &lt;/P&gt;&lt;P&gt;Month(TempDate) AS CalendarMonthName,&amp;nbsp; &lt;/P&gt;&lt;P&gt;'Q' &amp;amp; Ceil(Month(TempDate)/3) AS CalendarQuarter,&amp;nbsp; &lt;/P&gt;&lt;P&gt;Year(TempDate) AS CalendarYear,&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// Calendar Date Names&amp;nbsp; &lt;/P&gt;&lt;P&gt;WeekName(TempDate) as CalendarWeekNumberAndYear,&amp;nbsp; &lt;/P&gt;&lt;P&gt;MonthName(TempDate) as CalendarMonthAndYear,&amp;nbsp; &lt;/P&gt;&lt;P&gt;QuarterName(TempDate) as CalendarQuarterMonthsAndYear,&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// Start Dates&amp;nbsp; &lt;/P&gt;&lt;P&gt;DayStart(TempDate) as CalendarDayStart,&amp;nbsp; &lt;/P&gt;&lt;P&gt;WeekStart(TempDate) as CalendarWeekStart,&amp;nbsp; &lt;/P&gt;&lt;P&gt;MonthStart(TempDate) as CalendarMonthStart,&amp;nbsp; &lt;/P&gt;&lt;P&gt;QuarterStart(TempDate) as CalendarQuarterStart,&amp;nbsp; &lt;/P&gt;&lt;P&gt;YearStart(TempDate) as CalendarYearStart,&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// End Dates&amp;nbsp; &lt;/P&gt;&lt;P&gt;DayEnd(TempDate) as CalendarDayEnd,&amp;nbsp; &lt;/P&gt;&lt;P&gt;WeekEnd(TempDate) as CalendarWeekEnd,&amp;nbsp; &lt;/P&gt;&lt;P&gt;MonthEnd(TempDate) as CalendarMonthEnd,&amp;nbsp; &lt;/P&gt;&lt;P&gt;QuarterEnd(TempDate) as CalendarQuarterEnd,&amp;nbsp; &lt;/P&gt;&lt;P&gt;YearEnd(TempDate) as CalendarYearEnd,&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// Combo Date Examples&amp;nbsp; &lt;/P&gt;&lt;P&gt;'Q' &amp;amp; Ceil(Month(TempDate)/3) &amp;amp; '/' &amp;amp; Year(TempDate) AS CalendarQuarterAndYear,&amp;nbsp; &lt;/P&gt;&lt;P&gt;Year(TempDate) &amp;amp; '/' &amp;amp; 'Q' &amp;amp; Ceil(Month(TempDate)/3) AS CalendarYearAndQuarter,&amp;nbsp; &lt;/P&gt;&lt;P&gt;'Wed ' &amp;amp; DayStart(WeekStart(TempDate) + 3) as CalendarWednesdays&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RESIDENT TempCalendar ORDER BY TempDate ASC;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP TABLE TempCalendar;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET vDateMin = Num(MakeDate(2010,1,1));&amp;nbsp; &lt;/P&gt;&lt;P&gt;LET vDateMax = Floor(YearEnd(AddMonths(Today(), 12)));&amp;nbsp; &lt;/P&gt;&lt;P&gt;LET vDateToday = Num(Today());&amp;nbsp; &lt;/P&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 14:16:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295937#M109805</guid>
      <dc:creator />
      <dc:date>2012-02-20T14:16:10Z</dc:date>
    </item>
    <item>
      <title>Create calendar table that defines pay schedule</title>
      <link>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295938#M109806</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I see, it's not what I thought...&amp;nbsp; You want a value of payday for each date, and the rules are according to your example.&amp;nbsp; If I got the requirement right this time, here it is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(mod(date(floor(weekend(Date))) -2- $(PD), 14)=0, &lt;BR /&gt; date(floor(weekend(Date)+12)),&lt;BR /&gt; date(floor(weekend(Date)+5)))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried it in a calculated list box.&amp;nbsp; Can work as in expression in the chart or in the script, as an additional field in the master calendar.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards, &lt;/P&gt;&lt;P&gt;Michael&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2012 23:09:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-calendar-table-that-defines-pay-schedule/m-p/295938#M109806</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-02-20T23:09:57Z</dc:date>
    </item>
  </channel>
</rss>

