<?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: DISTINCT vs. DISTINCTROW in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/DISTINCT-vs-DISTINCTROW/m-p/537959#M691726</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;Below is the definition of DistintRow in access&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;Omits data based on entire duplicate records, not just duplicate fields. For example, you could create a query that joins the Customers and Orders tables on the CustomerID field. The Customers table contains no duplicate CustomerID fields, but the Orders table does because each customer can have many orders. The following SQL statement shows how you can use DISTINCTROW to produce a list of companies that have at least one order but without any details about those orders:&lt;/P&gt;&lt;PRE style="font-family: 'Courier New', Courier, monospace; padding: 8px 8px 8px 15px; background-color: #eeeeee; font-size: 1.4em; color: #444444;"&gt;&lt;CODE style="font-family: 'Courier New', Courier, monospace; font-size: 1.2em;"&gt;SELECT DISTINCTROW CompanyName FROM Customers INNER JOIN Orders ON Customers.CustomerID = Orders.CustomerID ORDER BY CompanyName; &lt;/CODE&gt;&lt;/PRE&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;If you omit DISTINCTROW, this query produces multiple rows for each company that has more than one order.&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;DISTINCTROW has an effect only when you select fields from some, but not all, of the tables used in the query. DISTINCTROW is ignored if your query includes only one table, or if you output fields from all tables.&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;"Taken from Microsoft Access Help"&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;In QlikView you would have to use Firstsortedvalue to achieve this, as you need only one record.&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;thanks,&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;Rajesh Vaswani&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 28 Aug 2013 04:01:58 GMT</pubDate>
    <dc:creator>rajeshvaswani77</dc:creator>
    <dc:date>2013-08-28T04:01:58Z</dc:date>
    <item>
      <title>DISTINCT vs. DISTINCTROW</title>
      <link>https://community.qlik.com/t5/QlikView/DISTINCT-vs-DISTINCTROW/m-p/537958#M691725</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;Hello to all.&amp;nbsp; I have a query in Access that I am trying to recreate in QlikView.&amp;nbsp; The first part of the query in Access is written as SELECT DISTINCTROW.&amp;nbsp; I have found no way of replicating SELECT DISTINCTROW in QlikView.&amp;nbsp; There is not way (that I know of) to SELECT DISTINCTROW in a LOAD statement.&amp;nbsp; I have tried simply SELECT DISTINCT, but do not get the same amount of records when using this method.&amp;nbsp; Has anyone ran into a similar problem?&amp;nbsp; Is there a way to SELECT DISTINCTROW?&amp;nbsp; Thank you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Aug 2013 21:28:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/DISTINCT-vs-DISTINCTROW/m-p/537958#M691725</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-08-27T21:28:32Z</dc:date>
    </item>
    <item>
      <title>Re: DISTINCT vs. DISTINCTROW</title>
      <link>https://community.qlik.com/t5/QlikView/DISTINCT-vs-DISTINCTROW/m-p/537959#M691726</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;Below is the definition of DistintRow in access&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;Omits data based on entire duplicate records, not just duplicate fields. For example, you could create a query that joins the Customers and Orders tables on the CustomerID field. The Customers table contains no duplicate CustomerID fields, but the Orders table does because each customer can have many orders. The following SQL statement shows how you can use DISTINCTROW to produce a list of companies that have at least one order but without any details about those orders:&lt;/P&gt;&lt;PRE style="font-family: 'Courier New', Courier, monospace; padding: 8px 8px 8px 15px; background-color: #eeeeee; font-size: 1.4em; color: #444444;"&gt;&lt;CODE style="font-family: 'Courier New', Courier, monospace; font-size: 1.2em;"&gt;SELECT DISTINCTROW CompanyName FROM Customers INNER JOIN Orders ON Customers.CustomerID = Orders.CustomerID ORDER BY CompanyName; &lt;/CODE&gt;&lt;/PRE&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;If you omit DISTINCTROW, this query produces multiple rows for each company that has more than one order.&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;DISTINCTROW has an effect only when you select fields from some, but not all, of the tables used in the query. DISTINCTROW is ignored if your query includes only one table, or if you output fields from all tables.&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;"Taken from Microsoft Access Help"&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;In QlikView you would have to use Firstsortedvalue to achieve this, as you need only one record.&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;thanks,&lt;/P&gt;&lt;P style="font-size: 14px; color: #444444; margin-bottom: 10px; font-family: 'Segoe UI', SegoeUIWF, Arial, sans-serif;"&gt;Rajesh Vaswani&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Aug 2013 04:01:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/DISTINCT-vs-DISTINCTROW/m-p/537959#M691726</guid>
      <dc:creator>rajeshvaswani77</dc:creator>
      <dc:date>2013-08-28T04:01:58Z</dc:date>
    </item>
  </channel>
</rss>

