<?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: Very Interesting task for scripting in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397895#M424170</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Would you be able to post some dummy data that best represents your scenario and the expected output?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 29 Aug 2017 05:52:58 GMT</pubDate>
    <dc:creator>vinieme12</dc:creator>
    <dc:date>2017-08-29T05:52:58Z</dc:date>
    <item>
      <title>Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397894#M424169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, guys!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Very intersting task for Qlikview scripting. &lt;/P&gt;&lt;P&gt;I have data set for ''project code'', "hours", "rate"&amp;nbsp; and "realization" rate.&lt;/P&gt;&lt;P&gt;The income is recognized when hours x rate x realization.&lt;/P&gt;&lt;P&gt;However, the realization changes over time.&lt;/P&gt;&lt;P&gt;When the realization changes the income is recongized by last available realization.&lt;/P&gt;&lt;P&gt;The formula should aggregate the value like "hours" ((1) x "rate" (1) + "hours" (2) + "rate" (2)) x realization (2). something like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I include the input data. Please propose any script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Ruslan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 05:42:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397894#M424169</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T05:42:25Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397895#M424170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Would you be able to post some dummy data that best represents your scenario and the expected output?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 05:52:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397895#M424170</guid>
      <dc:creator>vinieme12</dc:creator>
      <dc:date>2017-08-29T05:52:58Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397896#M424171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/thread/31487"&gt;How to get answers to your post?&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/docs/DOC-7538"&gt;Qlik Community Tip: Posting Successful Discussion Threads&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 05:54:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397896#M424171</guid>
      <dc:creator>vinieme12</dc:creator>
      <dc:date>2017-08-29T05:54:26Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397897#M424172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Inputting data. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The output should look like&lt;/P&gt;&lt;P&gt;&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;Job code&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Month&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;Result&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;June&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;5 x 10 000 x 30% &lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;456&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;June&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;6 x 10 000 x 30%&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;789&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;June&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;7 x 10 000 x 30%&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;July&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;(5 x 10 000 + 8 x 10 000) x 40%&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;456&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;July&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;(6 x 10 000 + 10 x 10 000) x 40%&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;789&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;July&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;(7 x 10 000 + 11 x 10 000) x 40%&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 06:01:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397897#M424172</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T06:01:56Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397898#M424173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;posted&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 06:02:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397898#M424173</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T06:02:14Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397899#M424174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Ruslan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Data:&lt;/P&gt;&lt;P&gt;LOAD Month, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Employee, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Job code], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HRS, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Rate&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;data.xlsx&lt;/P&gt;&lt;P&gt;(ooxml, embedded labels, table is Sheet1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Left Join(Data)&lt;/P&gt;&lt;P&gt;LOAD Month, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Job code], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Realization&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;[data 2.xlsx]&lt;/P&gt;&lt;P&gt;(ooxml, embedded labels, table is Sheet2);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE bgcolor="#ffffff" border="1" cellpadding="2" cellspacing="0" style="font-size: 9pt;"&gt;&lt;TBODY&gt;&lt;TR bgcolor="#f5f5f5"&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Job code&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;Month&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;TH nowrap="nowrap"&gt;&lt;SPAN style="color: #363636;"&gt;&lt;STRONG&gt;HRS*Rate*Realization/100&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;123&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;June&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;15000&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;123&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;July&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;32000&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;456&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;June&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;18000&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;456&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;July&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;40000&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;789&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;June&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;21000&lt;/SPAN&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;TR bgcolor="#ffffff"&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;789&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;SPAN style="color: #363636;"&gt;July&lt;/SPAN&gt;&lt;/TD&gt;&lt;TD bgcolor="#ffffff"&gt;&lt;P&gt;&lt;SPAN style="background-color: transparent; color: #363636; font-size: 9pt;"&gt;44000&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Andrew&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 07:51:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397899#M424174</guid>
      <dc:creator>effinty2112</dc:creator>
      <dc:date>2017-08-29T07:51:27Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397900#M424175</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank Andrew. But the task is not about simple multiplication.&lt;/P&gt;&lt;P&gt;The formula to be written in a way to add up previous monthes and current month and multiply total to current realization rate.&lt;/P&gt;&lt;P&gt;It reminds me aggregation function. But I cannot set up correct formula.&lt;/P&gt;&lt;P&gt;Please consider that option.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Ruslan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 07:57:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397900#M424175</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T07:57:24Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397901#M424176</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Ruslan,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Sorry - did not read carefully enough. will respond&lt;/P&gt;&lt;P&gt;Andrew&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 08:02:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397901#M424176</guid>
      <dc:creator>effinty2112</dc:creator>
      <dc:date>2017-08-29T08:02:49Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397902#M424177</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Your expression could be something like (this is in the UI, the script can be built using GROUP BY and a similar expression)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;=Sum(HRS * Rate) * FirstSortedValue(Realization, -RealizationMonthStart)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The only thing you need to add when reading the Realizations, is to convert the month (in what year is this month anyway) into a &lt;SPAN style="font-family: 'courier new', courier;"&gt;MonthStart()&lt;/SPAN&gt; date value and call it &lt;SPAN style="font-family: 'courier new', courier;"&gt;RealizationMonthStart&lt;/SPAN&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 08:21:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397902#M424177</guid>
      <dc:creator>Peter_Cammaert</dc:creator>
      <dc:date>2017-08-29T08:21:33Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397903#M424178</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, Peter!&lt;/P&gt;&lt;P&gt;I changed input "month" into date format. And loaded script as MonthStart (Month) into script editor. Then I just copied your expression but it didn't work out. &lt;/P&gt;&lt;P&gt;Is it possible if you share qvw file, where you test your expression?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Ruslan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 08:38:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397903#M424178</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T08:38:53Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397904#M424179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Data:&lt;/P&gt;&lt;P&gt;LOAD Month,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; num(month(Date#(Month,'MMMM'))) as MonthNum,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Employee,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Job code],&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; HRS,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Rate,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; HRS*Rate as HRSRate&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;[data (1).xlsx]&lt;/P&gt;&lt;P&gt;(ooxml, embedded labels, table is Sheet1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Left Join(Data)&lt;/P&gt;&lt;P&gt;LOAD Month,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Job code],&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Realization/100 as Realization&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;[data (1).xlsx]&lt;/P&gt;&lt;P&gt;(ooxml, embedded labels, table is Sheet2);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Final:&lt;/P&gt;&lt;P&gt;LOAD *,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; HRS_Rate*Realization as Results;&lt;/P&gt;&lt;P&gt;LOAD *,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if([Job code]&amp;lt;&amp;gt;Previous([Job code]),HRSRate,rangesum(HRSRate,Peek('HRS_Rate'))) as HRS_Rate&lt;/P&gt;&lt;P&gt;Resident Data&lt;/P&gt;&lt;P&gt;Order by [Job code],MonthNum;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP Table Data;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP Fields HRSRate,HRS_Rate;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.JPG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/174938_Capture.JPG" style="height: auto;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 09:49:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397904#M424179</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2017-08-29T09:49:26Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397905#M424180</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The logic is correct. &lt;/P&gt;&lt;P&gt;However, when I select July, the total amount is shown for June+July, despite the July amounts should be shown only. The aggregated value should be shown as total if I selected both months.&lt;/P&gt;&lt;P&gt;Could you please fix it?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Ruslan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 10:07:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397905#M424180</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T10:07:01Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397906#M424181</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Finally it worked out with this example. Unfortunately, when I transfer to existing data model not all job codes are recalculated. &lt;/P&gt;&lt;P&gt;let me share to you my qvw file?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Ruslan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 10:09:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397906#M424181</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T10:09:49Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397907#M424182</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What should be the Amount when you select July and when you select June &amp;amp; july?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 10:16:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397907#M424182</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2017-08-29T10:16:47Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397908#M424183</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When I select July, the formula should use realization for July. When I select June, the formula should select the realization for June, respectively. But when no selections made or selections of both months, the formula should use the latest available realization rate...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 10:19:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397908#M424183</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T10:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397909#M424184</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Please provide the expected output in all the scenario. I am still confused with requirement&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 10:29:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397909#M424184</guid>
      <dc:creator>Kushal_Chawda</dc:creator>
      <dc:date>2017-08-29T10:29:51Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397910#M424185</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The scenario 1: &lt;/P&gt;&lt;P&gt;Select &lt;STRONG&gt;June&lt;/STRONG&gt;:&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;job code&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;Month&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;HRS&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Rate&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;Realization&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;Result&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;June&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;5&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;10 000&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;30%&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;15 000&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;The same results for other job codes as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Select &lt;STRONG&gt;July&lt;/STRONG&gt;:&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" jive-data-cell="{&amp;quot;color&amp;quot;:&amp;quot;#575757&amp;quot;,&amp;quot;textAlign&amp;quot;:&amp;quot;left&amp;quot;,&amp;quot;padding&amp;quot;:&amp;quot;2&amp;quot;,&amp;quot;backgroundColor&amp;quot;:&amp;quot;transparent&amp;quot;,&amp;quot;fontFamily&amp;quot;:&amp;quot;arial,helvetica,sans-serif&amp;quot;,&amp;quot;verticalAlign&amp;quot;:&amp;quot;baseline&amp;quot;}" jive-data-header="{&amp;quot;color&amp;quot;:&amp;quot;#FFFFFF&amp;quot;,&amp;quot;backgroundColor&amp;quot;:&amp;quot;#6690BC&amp;quot;,&amp;quot;textAlign&amp;quot;:&amp;quot;center&amp;quot;,&amp;quot;padding&amp;quot;:&amp;quot;2&amp;quot;}" 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;Job code&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;Month&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;Hrs&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;Rate&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;Realization&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;Result&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Julty&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;8&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;10 000&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;40%&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;32 000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Select both Month or Select nothing&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;job code&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Month&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;Hrs&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;Rate&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;Realization&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;Results&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;123&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;-&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;13&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;10 000&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;40%&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;52 000&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it's clear.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 12:32:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397910#M424185</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T12:32:29Z</dc:date>
    </item>
    <item>
      <title>Re: Very Interesting task for scripting</title>
      <link>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397911#M424186</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Please see the script maybe due to the error in scrip I am unable to apply the formula:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Realizations:&lt;/P&gt;&lt;P&gt;LOAD&amp;nbsp; &lt;/P&gt;&lt;P&gt;Realisation, &lt;/P&gt;&lt;P&gt;[Job code]&amp;amp;'_'&amp;amp;Period as KEY&lt;/P&gt;&lt;P&gt;FROM [Data\Realizations by month.xlsx] (ooxml, embedded labels, table is Sheet1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MapRealization:&lt;/P&gt;&lt;P&gt;Mapping&lt;/P&gt;&lt;P&gt;LOAD Distinct KEY, Realisation&lt;/P&gt;&lt;P&gt;Resident Realizations;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Advisory:&lt;/P&gt;&lt;P&gt;LOAD BU, &lt;/P&gt;&lt;P&gt;[Client name], &lt;/P&gt;&lt;P&gt;[Job code], &lt;/P&gt;&lt;P&gt;[Eng. name], &lt;/P&gt;&lt;P&gt;[Work dt], &lt;/P&gt;&lt;P&gt;Period, &lt;/P&gt;&lt;P&gt;Month(Period) as Date,&lt;/P&gt;&lt;P&gt;QuarterStart(Period) as Quarter,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Hrs, &lt;/P&gt;&lt;P&gt;&amp;nbsp; Tr.Reference, &lt;/P&gt;&lt;P&gt;&amp;nbsp; Tr.Type, &lt;/P&gt;&lt;P&gt;&amp;nbsp; Descript, &lt;/P&gt;&lt;P&gt;&amp;nbsp; Ref., &lt;/P&gt;&lt;P&gt;&amp;nbsp; Entity, &lt;/P&gt;&lt;P&gt;&amp;nbsp; [Tr type], &lt;/P&gt;&lt;P&gt;&amp;nbsp; [Journ Type], &lt;/P&gt;&lt;P&gt;&amp;nbsp; [Empl code], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Empl name], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Empl office], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Empl&amp;nbsp; dep], &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Eng CC],&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; EngMan,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Job code]&amp;amp;'_'&amp;amp;Period as KEY,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ApplyMap('MapRealization', [Job code]&amp;amp;'_'&amp;amp;Period,40) as AdjRealization&lt;/P&gt;&lt;P&gt;FROM [Data\July'17 ch hours details_kz _emc.xls] (biff, embedded labels, table is Advisory$);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Inner Join (Advisory)&lt;/P&gt;&lt;P&gt;MC_Employees:&lt;/P&gt;&lt;P&gt;LOAD [Empl name], &lt;/P&gt;&lt;P&gt;Grade, &lt;/P&gt;&lt;P&gt;City, &lt;/P&gt;&lt;P&gt;Group, &lt;/P&gt;&lt;P&gt;Month(Period) as Date&lt;/P&gt;&lt;P&gt;FROM [Data\MC employee list.xlsx] (ooxml, embedded labels, table is Sheet1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MC_Rates:&lt;/P&gt;&lt;P&gt;LOAD Position as Grade, &lt;/P&gt;&lt;P&gt;[Rate (KZT)]&lt;/P&gt;&lt;P&gt;FROM [Data\MC rates in KZT.xlsx] (ooxml, embedded labels, table is Sheet1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Budget:&lt;/P&gt;&lt;P&gt;LOAD Month(Date) as Date, Group, Amount as BudgetAmount&lt;/P&gt;&lt;P&gt;FROM Data\Budget.xlsx (ooxml, embedded labels, table is Sheet1);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Aug 2017 14:08:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Very-Interesting-task-for-scripting/m-p/1397911#M424186</guid>
      <dc:creator>rassanbekov</dc:creator>
      <dc:date>2017-08-29T14:08:34Z</dc:date>
    </item>
  </channel>
</rss>

