<?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 Left Join and count in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Left-Join-and-count/m-p/190127#M52750</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;On a quick glance syntax might be o.k. Have you tried to run the script in parts and see the results in order to identify, where something obscure does happen? If the resident loads have the same number of fields than an existing table, you will not create a new table, hence also being unable to join.&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 17 Dec 2009 03:53:37 GMT</pubDate>
    <dc:creator>prieper</dc:creator>
    <dc:date>2009-12-17T03:53:37Z</dc:date>
    <item>
      <title>Left Join and count</title>
      <link>https://community.qlik.com/t5/QlikView/Left-Join-and-count/m-p/190126#M52749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear community,&lt;/P&gt;&lt;P&gt;I am doing a "left join" but it doesn't work as I excepted. Please have a look at the code and screenshot from the tables. I read the Help file and searched the forum, but since I am still not too familiar with all that functions of QV, I address this issue to you, too.&lt;/P&gt;&lt;P&gt;The problem seems to be located somewhere in table "Test5" as you can see on the image. There are no synth-keys in the script and the format of the column "DateHRS" is a timestamp ('dd.mm.yyyy hh'). Also there is the possibility of having more than one row per "DateHRS" in "Test 5" since you are having several IDs ("IDRZA"). The "count" function should generate a value ("CountX") based on other date (End1) that will be attached to all rows.&lt;/P&gt;&lt;P&gt;In the the "MAX table" I'd like to find the maximum value of "CountX" per "DateHRS"&lt;/P&gt;&lt;P&gt;Hope someone will have some minutes to check where the mistake is?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE ___default_attr="plain" class="jive_text_macro jive_macro_code" jivemacro="code"&gt;Test5:&lt;BR /&gt;Load&lt;BR /&gt; DateHRS,&lt;BR /&gt; MinKal&lt;BR /&gt;Resident Stundenkalender;&lt;BR /&gt;&lt;BR /&gt;Left join (Test5)&lt;BR /&gt;Load&lt;BR /&gt; DateHRS,&lt;BR /&gt; Ala2,&lt;BR /&gt; IDRZA,&lt;BR /&gt; Mon,&lt;BR /&gt; Weekd,&lt;BR /&gt; Ala1,&lt;BR /&gt; End1&lt;BR /&gt;Resident Test4;&lt;BR /&gt;&lt;BR /&gt;LEFT JOIN (Test5)&lt;BR /&gt;LOAD&lt;BR /&gt; Ala2,&lt;BR /&gt; Count(distinct if(ISNULL(End1),'0',End1)) AS CountX&lt;BR /&gt;Resident Test3&lt;BR /&gt;Group by Ala2;&lt;BR /&gt;&lt;BR /&gt;Drop table Test3;&lt;BR /&gt;Drop Table Test4;&lt;BR /&gt;&lt;BR /&gt;MAX:&lt;BR /&gt;LOAD&lt;BR /&gt; DateHRS,&lt;BR /&gt; dual(time(floor(MinKal, 1/24),'hh:mm') &amp;amp; ' - ' &amp;amp; time(ceil (MinKal, 1/24),'hh:mm'), floor(frac(MinKal),1/24)) as Stunden&lt;BR /&gt;Resident Test5;&lt;BR /&gt;&lt;BR /&gt;inner join&lt;BR /&gt;LOAD&lt;BR /&gt; DateHRS,&lt;BR /&gt; max(CountX) AS MAX&lt;BR /&gt;RESIDENT Test5&lt;BR /&gt;GROUP BY DateHRS;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Drop Table Stundenkalender;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for all comments,[:)]&lt;/P&gt;&lt;P&gt;Nico&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Dec 2009 00:59:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Left-Join-and-count/m-p/190126#M52749</guid>
      <dc:creator />
      <dc:date>2009-12-17T00:59:54Z</dc:date>
    </item>
    <item>
      <title>Left Join and count</title>
      <link>https://community.qlik.com/t5/QlikView/Left-Join-and-count/m-p/190127#M52750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;On a quick glance syntax might be o.k. Have you tried to run the script in parts and see the results in order to identify, where something obscure does happen? If the resident loads have the same number of fields than an existing table, you will not create a new table, hence also being unable to join.&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Dec 2009 03:53:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Left-Join-and-count/m-p/190127#M52750</guid>
      <dc:creator>prieper</dc:creator>
      <dc:date>2009-12-17T03:53:37Z</dc:date>
    </item>
  </channel>
</rss>

