<?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: CONCAT function with Sort weight in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1748256#M453442</link>
    <description>&lt;P&gt;I had to tweak little bit because I cannot drop the table as I have more than 100 columns and cannot mention all of them in group by.&lt;/P&gt;&lt;P&gt;I just took the key and the columns that need to be concatenated in a separate table using resident load and then applied the similar logic what you said. so, I can accept this as correct solution.&lt;/P&gt;</description>
    <pubDate>Tue, 29 Sep 2020 20:41:14 GMT</pubDate>
    <dc:creator>manideep78</dc:creator>
    <dc:date>2020-09-29T20:41:14Z</dc:date>
    <item>
      <title>CONCAT function with Sort weight</title>
      <link>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747901#M453414</link>
      <description>&lt;P&gt;Dear Community,&lt;/P&gt;&lt;P&gt;I have an input like table 1 and expecting output like table2.&lt;/P&gt;&lt;P&gt;I would like to use Concat function without distinct but my priority is sort order. My sort order is based on Col1 and Col2 and ignore the default concat sort.&lt;/P&gt;&lt;P&gt;either script function or chart function is fine, but recommend in script because I have to display my output in table box.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Table-1: Input&lt;/STRONG&gt;&lt;/P&gt;&lt;TABLE width="442"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="64"&gt;&lt;STRONG&gt;Col1&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD width="64"&gt;&lt;STRONG&gt;Col2&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD width="87"&gt;&lt;STRONG&gt;Col3&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD width="104"&gt;&lt;STRONG&gt;Col4&lt;/STRONG&gt;&lt;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P,Q,R&lt;/TD&gt;&lt;TD&gt;PP,PP,QQ,RR&lt;/TD&gt;&lt;TD&gt;200,350,250,300&lt;/TD&gt;&lt;TD&gt;PPP,PPP,QQQ,RRR&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 18:02:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747901#M453414</guid>
      <dc:creator>manideep78</dc:creator>
      <dc:date>2024-11-16T18:02:47Z</dc:date>
    </item>
    <item>
      <title>Re: CONCAT function with Sort weight</title>
      <link>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747975#M453416</link>
      <description>&lt;P&gt;PFA, IF this is what you expecting?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Concat.png" style="width: 343px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/41370iD486597EFFB45E0B/image-size/large?v=v2&amp;amp;px=999" role="button" title="Concat.png" alt="Concat.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 08:14:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747975#M453416</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2020-09-29T08:14:44Z</dc:date>
    </item>
    <item>
      <title>Re: CONCAT function with Sort weight</title>
      <link>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747984#M453417</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28937"&gt;@manideep78&lt;/a&gt;&amp;nbsp; May be this version :&lt;/P&gt;&lt;LI-CODE lang="python"&gt;Input:

LOAD * INLINE [
    Col1, Col2, Col3, Col4, Col5
    1, A, AA, 3, PQR
    1, B, BB, 1, ABC
    1, C, CC, 2, XYZ
    2, X, XX, 100, XXX
    2, Y, YY, 101, YYY
    3, P, PP, 200, PPP
    3, P, PP, 350, PPP
    3, Q, QQ, 250, QQQ
    3, R, RR, 300, RRR
];

output:
noconcatenate


load Col1,concat(Col2,',',recno()) as Col2,concat(Col3,',',recno()) as Col3,concat(Col4,',',recno()) as Col4,concat(Col5,',',recno()) as Col5 resident Input group by Col1;

drop table Input;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;output :&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 614px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/41372i92ACEFE30AA5B362/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 08:24:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747984#M453417</guid>
      <dc:creator>Taoufiq_Zarra</dc:creator>
      <dc:date>2020-09-29T08:24:07Z</dc:date>
    </item>
    <item>
      <title>Re: CONCAT function with Sort weight</title>
      <link>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747986#M453418</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/28937"&gt;@manideep78&lt;/a&gt;&amp;nbsp; or this :&lt;/P&gt;&lt;LI-CODE lang="python"&gt;Input:

LOAD *,rowno() as Numtmp INLINE [
    Col1, Col2, Col3, Col4, Col5
    1, A, AA, 3, PQR
    1, B, BB, 1, ABC
    1, C, CC, 2, XYZ
    2, X, XX, 100, XXX
    2, Y, YY, 101, YYY
    3, P, PP, 200, PPP
    3, P, PP, 350, PPP
    3, Q, QQ, 250, QQQ
    3, R, RR, 300, RRR
];

output:
noconcatenate


load Col1,concat(Col2,',',Numtmp) as Col2,concat(Col3,',',Numtmp) as Col3,concat(Col4,',',Numtmp) as Col4,concat(Col5,',',Numtmp) as Col5 resident Input group by Col1;

drop table Input;&lt;/LI-CODE&gt;&lt;P&gt;output:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 618px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/41373i77893A09A63C52B2/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 08:27:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1747986#M453418</guid>
      <dc:creator>Taoufiq_Zarra</dc:creator>
      <dc:date>2020-09-29T08:27:22Z</dc:date>
    </item>
    <item>
      <title>Re: CONCAT function with Sort weight</title>
      <link>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1748254#M453441</link>
      <description>&lt;P&gt;This has the sort issue in col4, row 3.&lt;/P&gt;&lt;P&gt;it should be&lt;/P&gt;&lt;TABLE width="442"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;200,350,250,300&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:38:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1748254#M453441</guid>
      <dc:creator>manideep78</dc:creator>
      <dc:date>2020-09-29T20:38:06Z</dc:date>
    </item>
    <item>
      <title>Re: CONCAT function with Sort weight</title>
      <link>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1748256#M453442</link>
      <description>&lt;P&gt;I had to tweak little bit because I cannot drop the table as I have more than 100 columns and cannot mention all of them in group by.&lt;/P&gt;&lt;P&gt;I just took the key and the columns that need to be concatenated in a separate table using resident load and then applied the similar logic what you said. so, I can accept this as correct solution.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 20:41:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/CONCAT-function-with-Sort-weight/m-p/1748256#M453442</guid>
      <dc:creator>manideep78</dc:creator>
      <dc:date>2020-09-29T20:41:14Z</dc:date>
    </item>
  </channel>
</rss>

