<?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: How join the calendar date in a proper way in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084600#M88906</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/85603"&gt;@Vinay_B&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks for the response. I tried your solution but I get this error.&lt;/P&gt;
&lt;DIV class="headline edc_error"&gt;The following error occurred:&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;Field 'user_id' not found&lt;/DIV&gt;
&lt;DIV class="empty edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="headline edc_error"&gt;The error occurred here:&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;ClockingData: LOAD date_stamp, user_id, total_time as working_shift RESIDENT Calendar&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;I am sure that the field names match the names in the data schema, but the issue here is probably that I don't have the user_id in the calendar?&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;Have you please another idea of how I get a table with all dates from the calendar for all user_id?&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;I tried some concat, and cross joins but everything was heavy or didn't work. Need some easy and lightweight solution.&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&lt;STRONG&gt;Maybe I didn't need to use the whole calendar because I need only a work week without the weekends but when I used only the date stamp from clocking, there are no public holiday dates so when I calculate the workload on a week where is a public holiday, I missed some days and workload percentages are wrong.&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;Thanks for your help.&lt;/DIV&gt;</description>
    <pubDate>Fri, 16 Jun 2023 05:42:06 GMT</pubDate>
    <dc:creator>jarokall</dc:creator>
    <dc:date>2023-06-16T05:42:06Z</dc:date>
    <item>
      <title>How join the calendar date in a proper way</title>
      <link>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084290#M88878</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I have generated a calendar in a DB... All dates with weekend and holiday flags.&lt;/P&gt;
&lt;P&gt;I try to figure out the proper way to join my Calendar date with the date from the clocking system. The clocking table has only working dates, so when I join it together, I lost the weekend and holiday dates.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to table all dates for each ID from the clocking table with data or nulls and then do some scripts/calculations on top of that like attendance (was or was not at work), etc.&lt;/P&gt;
&lt;P&gt;Have you please idea how to do it in a proper and fast way?&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;DIV&gt;[Calendar]:&lt;/DIV&gt;
&lt;DIV&gt;LOAD&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_date`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; date_stamp,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_day`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_work`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_holiday`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_name`;&lt;/DIV&gt;
&lt;DIV&gt;SQL SELECT&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_date`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_date` as date_stamp,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_day`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_work`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_holiday`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_name`&lt;/DIV&gt;
&lt;DIV&gt;FROM calendar.calendar as calendar;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;join(Calendar)&lt;/DIV&gt;
&lt;DIV&gt;LOAD&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt; date_stamp,&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; user_id,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; total_time as working_shift,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; ;&lt;/DIV&gt;
&lt;DIV&gt;SQL SELECT&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; rsch.date_stamp,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; rsch.user_id,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; rsch.total_time / 3600 as total_time&lt;/DIV&gt;
&lt;DIV&gt;FROM clocking.recurring_schedule as rsch&lt;/DIV&gt;
&lt;DIV&gt;;&lt;/DIV&gt;</description>
      <pubDate>Fri, 15 Nov 2024 21:40:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084290#M88878</guid>
      <dc:creator>jarokall</dc:creator>
      <dc:date>2024-11-15T21:40:41Z</dc:date>
    </item>
    <item>
      <title>Re: How join the calendar date in a proper way</title>
      <link>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084358#M88888</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/108960"&gt;@jarokall&lt;/a&gt;&amp;nbsp;Can you try the below and let me know how it goes?&lt;/P&gt;
&lt;P&gt;[Calendar]:&lt;BR /&gt;LOAD&lt;BR /&gt;`calendar_date`,&lt;BR /&gt;date_stamp,&lt;BR /&gt;`calendar_day`,&lt;BR /&gt;`calendar_work`,&lt;BR /&gt;`calendar_holiday`,&lt;BR /&gt;`calendar_name`;&lt;BR /&gt;SQL SELECT &lt;BR /&gt;`calendar_date`,&lt;BR /&gt;`calendar_date` as date_stamp,&lt;BR /&gt;`calendar_day`,&lt;BR /&gt;`calendar_work`,&lt;BR /&gt;`calendar_holiday`,&lt;BR /&gt;`calendar_name`&lt;BR /&gt;FROM calendar.calendar as calendar;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;ClockingData:&lt;BR /&gt;LOAD &lt;BR /&gt;date_stamp,&lt;BR /&gt;user_id,&lt;BR /&gt;total_time as working_shift&lt;BR /&gt;RESIDENT Calendar;&lt;/P&gt;
&lt;P&gt;LEFT JOIN(Calendar)&lt;BR /&gt;LOAD &lt;BR /&gt;date_stamp,&lt;BR /&gt;user_id,&lt;BR /&gt;total_time as working_shift&lt;BR /&gt;FROM clocking.recurring_schedule;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Note: Make sure the field names, such as &lt;/SPAN&gt;&lt;CODE&gt;calendar_date&lt;/CODE&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;CODE&gt;date_stamp&lt;/CODE&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;CODE&gt;user_id&lt;/CODE&gt;&lt;SPAN&gt;, and &lt;/SPAN&gt;&lt;CODE&gt;total_time&lt;/CODE&gt;&lt;SPAN&gt;, match the field names in your actual data schema.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Jun 2023 14:09:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084358#M88888</guid>
      <dc:creator>Vinay_B</dc:creator>
      <dc:date>2023-06-15T14:09:36Z</dc:date>
    </item>
    <item>
      <title>Re: How join the calendar date in a proper way</title>
      <link>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084600#M88906</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/85603"&gt;@Vinay_B&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks for the response. I tried your solution but I get this error.&lt;/P&gt;
&lt;DIV class="headline edc_error"&gt;The following error occurred:&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;Field 'user_id' not found&lt;/DIV&gt;
&lt;DIV class="empty edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="headline edc_error"&gt;The error occurred here:&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;ClockingData: LOAD date_stamp, user_id, total_time as working_shift RESIDENT Calendar&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;I am sure that the field names match the names in the data schema, but the issue here is probably that I don't have the user_id in the calendar?&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;Have you please another idea of how I get a table with all dates from the calendar for all user_id?&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;I tried some concat, and cross joins but everything was heavy or didn't work. Need some easy and lightweight solution.&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&lt;STRONG&gt;Maybe I didn't need to use the whole calendar because I need only a work week without the weekends but when I used only the date stamp from clocking, there are no public holiday dates so when I calculate the workload on a week where is a public holiday, I missed some days and workload percentages are wrong.&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="edc_error"&gt;Thanks for your help.&lt;/DIV&gt;</description>
      <pubDate>Fri, 16 Jun 2023 05:42:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084600#M88906</guid>
      <dc:creator>jarokall</dc:creator>
      <dc:date>2023-06-16T05:42:06Z</dc:date>
    </item>
    <item>
      <title>Re: How join the calendar date in a proper way</title>
      <link>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084612#M88910</link>
      <description>&lt;DIV&gt;
&lt;DIV&gt;recurring_schedule:&lt;/DIV&gt;
&lt;DIV&gt;LOAD&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;STRONG&gt;Date(date_stamp,'DD/MM/YYYY') as calendar_date,&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;DIV&gt;date_stamp,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; user_id,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; total_time as working_shift,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; ;&lt;/DIV&gt;
&lt;DIV&gt;SQL SELECT&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; rsch.date_stamp,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; rsch.user_id,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; rsch.total_time / 3600 as total_time&lt;/DIV&gt;
&lt;DIV&gt;FROM clocking.recurring_schedule as rsch&lt;/DIV&gt;
&lt;DIV&gt;;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;[Calendar]:&lt;/DIV&gt;
&lt;DIV&gt;&lt;STRONG&gt;Left Join&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;DIV&gt;LOAD&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_date`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; date_stamp,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_day`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_work`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_holiday`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_name`;&lt;/DIV&gt;
&lt;DIV&gt;SQL SELECT&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_date`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_date` as date_stamp,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_day`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_work`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_holiday`,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; `calendar_name`&lt;/DIV&gt;
&lt;DIV&gt;FROM calendar.calendar as calendar;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;hope this helps&lt;/DIV&gt;</description>
      <pubDate>Fri, 16 Jun 2023 06:33:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/How-join-the-calendar-date-in-a-proper-way/m-p/2084612#M88910</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2023-06-16T06:33:14Z</dc:date>
    </item>
  </channel>
</rss>

