<?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: Need assistance in script to get the first record - in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917709#M75490</link>
    <description>&lt;P&gt;Hi Rob,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;First won't work as I have different sets of records ....which i need to show but its different id,Facility Id, Service Repord id...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The first 1 will only show the first record of the full data set , but my req is something like below -&lt;/P&gt;
&lt;P&gt;How to pick the first record of&amp;nbsp; each set in qlikview script.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ashmitp869_0-1649800689498.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/76932iDF7D28BCBEEE55A5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ashmitp869_0-1649800689498.png" alt="ashmitp869_0-1649800689498.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 12 Apr 2022 21:58:40 GMT</pubDate>
    <dc:creator>ashmitp869</dc:creator>
    <dc:date>2022-04-12T21:58:40Z</dc:date>
    <item>
      <title>Need assistance in script to get the first record -</title>
      <link>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917325#M75471</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;
&lt;P&gt;Please help me with the script.&lt;/P&gt;
&lt;P&gt;SE_TMP:&lt;BR /&gt;Load&lt;BR /&gt;[Facility Identifier],&lt;BR /&gt;"Derived National Service Event Record Id",&lt;BR /&gt;"SE.Service Event Record ID",&lt;BR /&gt;1 as count_se&lt;BR /&gt;1 as count_oos&lt;BR /&gt;FROM&lt;BR /&gt;QVD;&lt;/P&gt;
&lt;P&gt;SE:&lt;BR /&gt;NoConcatenate&lt;BR /&gt;LOAD DISTINCT&lt;BR /&gt;"OOS.Derived National Service Event Record Id" as IDKey,&lt;BR /&gt;[Facility Identifier],&lt;BR /&gt;"SE.Service Event Record ID",&lt;BR /&gt;1 as count_se&lt;BR /&gt;0 as count_oos&lt;BR /&gt;RESIDENT OOS&lt;BR /&gt;WHERE NOT EXISTS ("Derived National Service Event Record Id","OOS.Derived National Service Event Record Id")&lt;BR /&gt;;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Concatenate(SE)&lt;BR /&gt;LOAD&lt;BR /&gt;"Derived National Service Event Record Id" as IDKey,&lt;BR /&gt;"Facility Identifier" &lt;BR /&gt;,"SE.Service Event Record ID"&lt;BR /&gt;,count_se as SE.count_se&lt;BR /&gt;,count_moh_se as SE.count_moh_se&lt;BR /&gt;RESIDENT SE_TMP;&lt;/P&gt;
&lt;P&gt;DROP TABLE SE_TMP;&lt;/P&gt;
&lt;P&gt;from the middle script , I am getting two records becoz of different&amp;nbsp;SE.Service Event Record ID .i.e below script&lt;/P&gt;
&lt;P&gt;SE:&lt;BR /&gt;NoConcatenate&lt;BR /&gt;LOAD DISTINCT&lt;BR /&gt;"OOS.Derived National Service Event Record Id" as IDKey,&lt;BR /&gt;[Facility Identifier],&lt;BR /&gt;"SE.Service Event Record ID",&lt;BR /&gt;1 as count_se&lt;BR /&gt;0 as count_oos&lt;BR /&gt;RESIDENT OOS&lt;BR /&gt;WHERE NOT EXISTS ("Derived National Service Event Record Id","OOS.Derived National Service Event Record Id")&lt;BR /&gt;;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is there any way I get the every first row the the distinct record in RESIDENT table ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is an eg , I have to get the distinct record depending on&amp;nbsp;erived National Service Event Record Id not&amp;nbsp;Service Event Record ID. I can understand why my distinct is not working becoz this are two record&amp;nbsp; because of&amp;nbsp;Service Event Record ID&lt;/P&gt;
&lt;P&gt;Is there any way in qlikview script where I can only pick the first record ?&lt;/P&gt;</description>
      <pubDate>Tue, 12 Apr 2022 09:03:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917325#M75471</guid>
      <dc:creator>ashmitp869</dc:creator>
      <dc:date>2022-04-12T09:03:21Z</dc:date>
    </item>
    <item>
      <title>Re: Need assistance in script to get the first record -</title>
      <link>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917499#M75483</link>
      <description>&lt;P&gt;You can use the LOAD prefix First n to select the first n rows.&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;First 1&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;-Rob&lt;/P&gt;</description>
      <pubDate>Tue, 12 Apr 2022 14:28:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917499#M75483</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2022-04-12T14:28:34Z</dc:date>
    </item>
    <item>
      <title>Re: Need assistance in script to get the first record -</title>
      <link>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917709#M75490</link>
      <description>&lt;P&gt;Hi Rob,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;First won't work as I have different sets of records ....which i need to show but its different id,Facility Id, Service Repord id...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The first 1 will only show the first record of the full data set , but my req is something like below -&lt;/P&gt;
&lt;P&gt;How to pick the first record of&amp;nbsp; each set in qlikview script.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ashmitp869_0-1649800689498.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/76932iDF7D28BCBEEE55A5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ashmitp869_0-1649800689498.png" alt="ashmitp869_0-1649800689498.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 12 Apr 2022 21:58:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917709#M75490</guid>
      <dc:creator>ashmitp869</dc:creator>
      <dc:date>2022-04-12T21:58:40Z</dc:date>
    </item>
    <item>
      <title>Re: Need assistance in script to get the first record -</title>
      <link>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917726#M75491</link>
      <description>&lt;P&gt;I would think you can just create a new dummy field as you load to use in Not Exists().&amp;nbsp; For example.&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN class="s1"&gt;Data:&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN class="s2"&gt;LOAD&lt;/SPAN&gt;&lt;SPAN class="s1"&gt; * &lt;/SPAN&gt;&lt;SPAN class="s2"&gt;INLINE&lt;/SPAN&gt; [&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Id, Name&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;abc, Rob&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;abc, Sally&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;def, John&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;def, Linda&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;zzz, Ralph&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;]&lt;SPAN class="s1"&gt;&lt;BR /&gt;;&lt;BR /&gt;&lt;BR /&gt;Firsties:&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN class="s2"&gt;LOAD&lt;/SPAN&gt;&lt;SPAN class="s1"&gt; &lt;BR /&gt;&amp;nbsp; *,&lt;BR /&gt;&lt;/SPAN&gt;&amp;nbsp; Id &lt;SPAN class="s2"&gt;as&lt;/SPAN&gt; &lt;STRONG&gt;FirstId&lt;/STRONG&gt;&lt;SPAN class="s1"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN class="s2"&gt;Resident&lt;/SPAN&gt;&lt;SPAN class="s1"&gt; Data&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN class="s2"&gt;Where&lt;/SPAN&gt; &lt;SPAN class="s2"&gt;Not&lt;/SPAN&gt; &lt;SPAN class="s2"&gt;Exists&lt;/SPAN&gt;&lt;SPAN class="s1"&gt;(&lt;/SPAN&gt;&lt;STRONG&gt;FirstId&lt;/STRONG&gt;&lt;SPAN class="s1"&gt;, &lt;/SPAN&gt;Id&lt;SPAN class="s1"&gt;)&lt;BR /&gt;; &lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN class="s2"&gt;DROP&lt;/SPAN&gt; &lt;SPAN class="s2"&gt;Table&lt;/SPAN&gt;&lt;SPAN class="s1"&gt; Data;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN class="s2"&gt;DROP&lt;/SPAN&gt; &lt;SPAN class="s2"&gt;Field&lt;/SPAN&gt; &lt;STRONG&gt;FirstId&lt;/STRONG&gt;&lt;SPAN class="s1"&gt;;&lt;SPAN class="Apple-converted-space"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class="p1"&gt;-Rob&lt;BR /&gt;&lt;A href="http://www.easyqlik.com" target="_blank"&gt;http://www.easyqlik.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://masterssummit.com" target="_blank"&gt;http://masterssummit.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://qlikviewcookbook.com" target="_blank"&gt;http://qlikviewcookbook.com&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 12 Apr 2022 23:26:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Need-assistance-in-script-to-get-the-first-record/m-p/1917726#M75491</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2022-04-12T23:26:33Z</dc:date>
    </item>
  </channel>
</rss>

