<?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: Swap two rows in pivot table in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705497#M254347</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Load your raw-data in qv then make a resident load over the first load to have the possibility to sort your data (order by statement) and the you could use peek() or previous() to compare and exchange the data from actual row with the from previous row respectively to n-rows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 16 Sep 2014 07:35:34 GMT</pubDate>
    <dc:creator>marcus_sommer</dc:creator>
    <dc:date>2014-09-16T07:35:34Z</dc:date>
    <item>
      <title>Swap two rows in pivot table</title>
      <link>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705493#M254343</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello there,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; My question is: Is there a way to swap two rows in pivot table?&amp;nbsp; Lets give the following example:&lt;/P&gt;&lt;P&gt;We got table:&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" style="border: 1px solid rgb(0, 0, 0); width: 100%;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Header 1&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Header 2&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Header 3&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Header 4&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;A&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;123123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;das132a&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;11223&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;B&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;523123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;fgg2212&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;asad&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;G&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;123124&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;sda5123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;3311s&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;J&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;123215&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;f123f&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;21312&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;Z&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;123555&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;5235&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;dfd&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Lets say Column 2 -&amp;gt; Header 2&amp;nbsp; is Expression or Calculated Dimension. Header 3 is expression too or Calc. Dimen. so is Header 4 too.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We got in Header 2:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=IF(above([Header 2])&amp;gt;[Header 2],.......swap ROW1 with ROW2 somehow............,[Header 2])&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Sep 2014 06:40:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705493#M254343</guid>
      <dc:creator />
      <dc:date>2014-09-16T06:40:07Z</dc:date>
    </item>
    <item>
      <title>Re: Swap two rows in pivot table</title>
      <link>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705494#M254344</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not sure what you want to do? You want any kind of sorting-logic? If you want swap or replace some parts from rows its better done within the script - with previous() and/or peek() could you look into the values of other rows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Sep 2014 07:06:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705494#M254344</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2014-09-16T07:06:28Z</dc:date>
    </item>
    <item>
      <title>Re: Swap two rows in pivot table</title>
      <link>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705495#M254345</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I want to swap data in Row 1 (header 1 A) with data in Row 2 (header 1 B).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Sep 2014 07:13:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705495#M254345</guid>
      <dc:creator />
      <dc:date>2014-09-16T07:13:22Z</dc:date>
    </item>
    <item>
      <title>Re: Swap two rows in pivot table</title>
      <link>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705496#M254346</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You need to do that kind of transformation in the script side&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Sep 2014 07:16:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705496#M254346</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-16T07:16:15Z</dc:date>
    </item>
    <item>
      <title>Re: Swap two rows in pivot table</title>
      <link>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705497#M254347</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Load your raw-data in qv then make a resident load over the first load to have the possibility to sort your data (order by statement) and the you could use peek() or previous() to compare and exchange the data from actual row with the from previous row respectively to n-rows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Sep 2014 07:35:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Swap-two-rows-in-pivot-table/m-p/705497#M254347</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2014-09-16T07:35:34Z</dc:date>
    </item>
  </channel>
</rss>

