<?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: How to create/Get YTD average  for a derived expression in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336421#M412172</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You will have Month and Day as a dimension or this was just to show how the data is laid out? Is this expression for a text box object? Try like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;=Num(Avg(&lt;SPAN style="color: #ff0000;"&gt;{&amp;lt;Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;}&lt;/SPAN&gt; Aggr(Count(&lt;SPAN style="color: #ff0000;"&gt;{&amp;lt;Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;}&lt;/SPAN&gt; DISTINCT ID_A)/Count(&lt;SPAN style="color: #ff0000;"&gt;{&amp;lt;Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;}&lt;/SPAN&gt; DISTINCT person), Day, Month, Year)),'##0.0')&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You need to replace DateFieldFormatHere with the format of your Date field.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 07 Jul 2017 08:37:00 GMT</pubDate>
    <dc:creator>sunny_talwar</dc:creator>
    <dc:date>2017-07-07T08:37:00Z</dc:date>
    <item>
      <title>How to create/Get YTD average  for a derived expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336418#M412169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good day,&lt;/P&gt;&lt;P&gt;I have a business requirement to present YTD % achieved based on Target value.&lt;/P&gt;&lt;P&gt;in this actual value is derived value expression&amp;nbsp;&amp;nbsp; based on daily &lt;/P&gt;&lt;P&gt;expression to get daily Actual value&amp;nbsp;&amp;nbsp; :- &lt;/P&gt;&lt;P&gt;=num(Avg(aGGR((Count({&amp;lt;TYPE={181,182},D_PK= {"=D_Date=D_min_Date"}&amp;gt;}DISTINCT ID_A))&lt;/P&gt;&lt;P&gt;/Count({&amp;lt;User_Type= {"Screener"}&amp;gt;}DISTINCTperson),Day,Month,Year)),'##0.0')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Now YTD budget :-&lt;/P&gt;&lt;P&gt;avg({&amp;lt;Type={'Production'},D_Month_Name_Num={'&amp;lt;=$(=max({&amp;lt;Flag={Y}&amp;gt;}D_Month_Name_Num))'},Month=&amp;gt;}Daily_Budget)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;From above 2 expression how do I derive YTD expression??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;appreciate some help on this , may this could be easy one ,&amp;nbsp; I am a &lt;SPAN style="font-size: 10pt; font-family: Arial, sans-serif;"&gt;beginner &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jul 2017 07:19:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336418#M412169</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-07-06T07:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to create/Get YTD average  for a derived expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336419#M412170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It might be easier to help if you can share a sample for us to take a look at.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/docs/DOC-1290"&gt;Preparing examples for Upload - Reduction and Data Scrambling&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/docs/DOC-16454"&gt;Uploading a Sample&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jul 2017 16:42:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336419#M412170</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-07-06T16:42:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to create/Get YTD average  for a derived expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336420#M412171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you so much for quick responds&lt;/P&gt;&lt;P&gt;I may make it bit more simple . a derived expression productivity on daily basis rollup to YTD&lt;/P&gt;&lt;P&gt;Productivity =count ID_A/count of person on Daily&lt;/P&gt;&lt;P&gt;Count =&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;DISTINCT ID_A&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Person=&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;DISTINCTperson&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Expression used in Application &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;=num(Avg(aGGR((Count(DISTINCT ID_A)) /Count(DISTINCTperson),Day,Month,Year)),'##0.0')&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Now how to get YTD Average on this?? &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="YTD.png" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/169370_YTD.png" style="height: auto;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jul 2017 18:51:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336420#M412171</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-07-06T18:51:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to create/Get YTD average  for a derived expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336421#M412172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You will have Month and Day as a dimension or this was just to show how the data is laid out? Is this expression for a text box object? Try like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;=Num(Avg(&lt;SPAN style="color: #ff0000;"&gt;{&amp;lt;Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;}&lt;/SPAN&gt; Aggr(Count(&lt;SPAN style="color: #ff0000;"&gt;{&amp;lt;Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;}&lt;/SPAN&gt; DISTINCT ID_A)/Count(&lt;SPAN style="color: #ff0000;"&gt;{&amp;lt;Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;}&lt;/SPAN&gt; DISTINCT person), Day, Month, Year)),'##0.0')&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You need to replace DateFieldFormatHere with the format of your Date field.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Jul 2017 08:37:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336421#M412172</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-07-07T08:37:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to create/Get YTD average  for a derived expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336422#M412173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you, &lt;/P&gt;&lt;P&gt;Its is a text value&amp;nbsp; and i am having problem in&amp;nbsp; the same , (i am getting YTD for Chart value,)&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;can you help me&amp;nbsp; i have&amp;nbsp; &lt;/SPAN&gt;amended&lt;SPAN style="font-size: 10pt;"&gt; the script&amp;nbsp; as below, but no value reflecting in text. I think I am doing something wrong ? is date format is &lt;/SPAN&gt;important, how do i specify the format, do you have any eg?&lt;SPAN style="font-size: 10pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=Num(Avg({&amp;lt;Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;} Aggr(Count({&amp;lt;ID_DA_UPDATE_TYPE={12,43,45,89},DA_PK= {"=ONLY({1}DA_Date)=ONLY({&amp;lt;Month=&amp;gt;}DA_min_Date)"},Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;} DISTINCT ID_DA)/Count({&amp;lt;User_Type= {"Screener"},Date = {"$(='&amp;gt;=' &amp;amp; Date(YearStart(Max(Date)), 'DateFieldFormatHere') &amp;amp; '&amp;lt;=' &amp;amp; Date(Max(Date), 'DateFieldFormatHere'))"}&amp;gt;} DISTINCT PDA_Screener), Day, Month, Year)),'##0.0')&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Jul 2017 11:07:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336422#M412173</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-07-07T11:07:58Z</dc:date>
    </item>
    <item>
      <title>Re: How to create/Get YTD average  for a derived expression</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336423#M412174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Look here for &lt;A href="https://community.qlik.com/qlik-blogpost/4394"&gt;Dates in Set Analysis&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Jul 2017 12:29:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-create-Get-YTD-average-for-a-derived-expression/m-p/1336423#M412174</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2017-07-07T12:29:53Z</dc:date>
    </item>
  </channel>
</rss>

