<?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: Expression help in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240684#M862375</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;if(Period ='JAN-17',Sum(unpriced_lots)-((Sum(unpriced_lots)/NetWorkDays(today(),final_pricing_dt))*(NetWorkDays(today()-1,final_pricing_dt)-3))&amp;nbsp; ,0)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 13 Jan 2017 10:59:06 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2017-01-13T10:59:06Z</dc:date>
    <item>
      <title>Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240679#M862368</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: arial,helvetica,sans-serif; font-size: 10pt;"&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: arial,helvetica,sans-serif; font-size: 10pt;"&gt;Please can you help with the following expression.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: arial,helvetica,sans-serif; font-size: 10pt;"&gt;I would like to add an IF clause for when Period is JAN-17 else 0.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: arial,helvetica,sans-serif; font-size: 10pt;"&gt;=&lt;SPAN style="color: #0000ff;"&gt;Sum&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;unpriced_lots&lt;/SPAN&gt;)-((&lt;SPAN style="color: #0000ff;"&gt;Sum&lt;/SPAN&gt;(&lt;SPAN style="color: #800000;"&gt;unpriced_lots&lt;/SPAN&gt;)/&lt;SPAN style="color: #0000ff;"&gt;NetWorkDays&lt;/SPAN&gt;(&lt;SPAN style="color: #0000ff;"&gt;today&lt;/SPAN&gt;(),&lt;SPAN style="color: #800000;"&gt;final_pricing_dt&lt;/SPAN&gt;))*(&lt;SPAN style="color: #0000ff;"&gt;NetWorkDays&lt;/SPAN&gt;(&lt;SPAN style="color: #0000ff;"&gt;today&lt;/SPAN&gt;()-1,&lt;SPAN style="color: #800000;"&gt;final_pricing_dt&lt;/SPAN&gt;)-3)) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: arial,helvetica,sans-serif; font-size: 10pt;"&gt;Thanks,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; font-family: arial,helvetica,sans-serif;"&gt;Daniel&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240679#M862368</guid>
      <dc:creator>danielnevitt</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240680#M862369</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(MonthStart(Period) = MakeDate(2017, 1, 1), Sum(unpriced_lots)-((Sum(unpriced_lots)/NetWorkDays(today(),final_pricing_dt))*(NetWorkDays(today()-1,final_pricing_dt)-3)), 0)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or you might be able to use set analysis also.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2017 17:54:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240680#M862369</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-12T17:54:05Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240681#M862370</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This expression only works if the field Period has only one possible value. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If there are many periods and you want to only calculate the sum for one particular period, then the same IF() condition (or a Set Analysis condition) needs to be added within each one of the aggregation functions mentioned here.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers,&lt;/P&gt;&lt;P&gt;Oleg Troyansky&lt;/P&gt;&lt;P&gt;Upgrade your Qlik skills at the &lt;A href="http://masterssummit.com/"&gt;Masters Summit for Qlik&lt;/A&gt; - coming soon to Munich, Germany!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jan 2017 18:08:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240681#M862370</guid>
      <dc:creator>Oleg_Troyansky</dc:creator>
      <dc:date>2017-01-12T18:08:29Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240682#M862372</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the replies.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sunny - unfortunately the code doesn't work as I believe the period is actually a text field.&amp;nbsp; Is it possible to incorporate JAN-17 in the expression.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jan 2017 10:02:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240682#M862372</guid>
      <dc:creator>danielnevitt</dc:creator>
      <dc:date>2017-01-13T10:02:17Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240683#M862374</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;If(Period = 'JAN-17', Sum(unpriced_lots)-((Sum(unpriced_lots)/NetWorkDays(today(),final_pricing_dt))*(NetWorkDays(today()-1,final_pricing_dt)-3)), 0)&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jan 2017 10:28:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240683#M862374</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-13T10:28:48Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240684#M862375</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;if(Period ='JAN-17',Sum(unpriced_lots)-((Sum(unpriced_lots)/NetWorkDays(today(),final_pricing_dt))*(NetWorkDays(today()-1,final_pricing_dt)-3))&amp;nbsp; ,0)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jan 2017 10:59:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240684#M862375</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-01-13T10:59:06Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240685#M862377</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your help, that worked perfectly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Last question I have is, is there a way of calculating the last working day from a date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, I would like to say final_pricing_dt - 3 networkdays.&amp;nbsp; Final_pricing_dt is 28/02/2017, therefore I would expect the result to be 24/02/2017.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jan 2017 11:35:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240685#M862377</guid>
      <dc:creator>danielnevitt</dc:creator>
      <dc:date>2017-01-13T11:35:10Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240686#M862379</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use a FirstWorkDay Function (&lt;A href="http://qlikshare.com/using-firstworkdate-function-qlikview/" title="http://qlikshare.com/using-firstworkdate-function-qlikview/"&gt;Using FirstWorkDate() function in QlikView - QlikView Blog, QlikView Videos and Tips at QlikShare&lt;/A&gt;)&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;=FirstWorkDate(MonthEnd(Today(), 1), 3)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/149384_Capture.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jan 2017 11:47:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240686#M862379</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-13T11:47:29Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240687#M862381</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank again Sunny.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to incorporate the field final_pricing_dt, as this might not always be the last day of the month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jan 2017 11:52:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240687#M862381</guid>
      <dc:creator>danielnevitt</dc:creator>
      <dc:date>2017-01-13T11:52:17Z</dc:date>
    </item>
    <item>
      <title>Re: Expression help</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240688#M862386</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The above was an example, you can add your field name in place of the Today() function&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;=FirstWorkDate(MonthEnd(&lt;SPAN style="color: #ff0000; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;final_pricing_dt&lt;/SPAN&gt;), 3)&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Jan 2017 11:57:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-help/m-p/1240688#M862386</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-01-13T11:57:29Z</dc:date>
    </item>
  </channel>
</rss>

