<?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: Create new variable using same columns in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959844#M649653</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you want this calculation to happen at back end then you have to add a group by to the table to group data at quarter level and sort it in ascending order then use previous function to calculate it as a Field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want the same in variable you will have to do group by and capture the details to a varialbe with peek function.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But the simplest way should be to do it in the front end like sum({&amp;lt;Quarter={'current_quarter'}&amp;gt;}sales)/sum({&amp;lt;Quarter={'previous_quarter'}&amp;gt;}sales). -1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can you explain why you want it in a variable?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Sundar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 20 Aug 2015 12:34:31 GMT</pubDate>
    <dc:creator>sundarakumar</dc:creator>
    <dc:date>2015-08-20T12:34:31Z</dc:date>
    <item>
      <title>Create new variable using same columns</title>
      <link>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959843#M649652</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have my data set like this &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="225"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD height="20" width="64"&gt;Vendor&lt;/TD&gt;&lt;TD width="64"&gt;Quarter&lt;/TD&gt;&lt;TD width="97"&gt;Current quarter&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q3 2013&lt;/TD&gt;&lt;TD align="right"&gt;100&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q2 2013&lt;/TD&gt;&lt;TD align="right"&gt;200&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q1 2013&lt;/TD&gt;&lt;TD align="right"&gt;300&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q4 2013&lt;/TD&gt;&lt;TD align="right"&gt;100&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q3 2013&lt;/TD&gt;&lt;TD align="right"&gt;200&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q2 2013&lt;/TD&gt;&lt;TD align="right"&gt;300&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q1 2013&lt;/TD&gt;&lt;TD align="right"&gt;100&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD height="20"&gt;Market&lt;/TD&gt;&lt;TD&gt;Q4 2013&lt;/TD&gt;&lt;TD align="right"&gt;200&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;I want new variable "Growth" so that&amp;nbsp; , growth of Q4 will be calculated from Current quater. and like wise for other quaters as well..&lt;/P&gt;&lt;P&gt;for ex. growth= q4/q3-1&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 06:25:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959843#M649652</guid>
      <dc:creator />
      <dc:date>2015-08-20T06:25:14Z</dc:date>
    </item>
    <item>
      <title>Re: Create new variable using same columns</title>
      <link>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959844#M649653</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you want this calculation to happen at back end then you have to add a group by to the table to group data at quarter level and sort it in ascending order then use previous function to calculate it as a Field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want the same in variable you will have to do group by and capture the details to a varialbe with peek function.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But the simplest way should be to do it in the front end like sum({&amp;lt;Quarter={'current_quarter'}&amp;gt;}sales)/sum({&amp;lt;Quarter={'previous_quarter'}&amp;gt;}sales). -1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can you explain why you want it in a variable?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Sundar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 12:34:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959844#M649653</guid>
      <dc:creator>sundarakumar</dc:creator>
      <dc:date>2015-08-20T12:34:31Z</dc:date>
    </item>
    <item>
      <title>Re: Create new variable using same columns</title>
      <link>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959845#M649654</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I need a separate variable ...doing it for the ease of use to see the growth rate.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I didn't get your 1st two lines....can you show what are you trying to say?&lt;/P&gt;&lt;P&gt;I am new to this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 13:41:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959845#M649654</guid>
      <dc:creator />
      <dc:date>2015-08-20T13:41:49Z</dc:date>
    </item>
    <item>
      <title>Re: Create new variable using same columns</title>
      <link>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959846#M649655</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;PFA the sample. It shows the exaple where the requirement is handled in script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But it is better to be calcualted in the front end like (in a text box)&lt;/P&gt;&lt;P&gt;=(sum({&amp;lt;Quarter={'2015 Q4'}&amp;gt;}sales)/sum({&amp;lt;Quarter={'2015 Q3'}&amp;gt;}sales))-1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Sundar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 13:56:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-new-variable-using-same-columns/m-p/959846#M649655</guid>
      <dc:creator>sundarakumar</dc:creator>
      <dc:date>2015-08-20T13:56:49Z</dc:date>
    </item>
  </channel>
</rss>

