<?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 Gauge in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599120#M737224</link>
    <description>&lt;P&gt;I'm looking to create a gauge that works differently depending on what has been selected from the calendar.&lt;/P&gt;&lt;P&gt;so, if [CalMonth] is selected the calculation needs to be&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Count((BedDaysPatientID))&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;((Sum({&amp;lt;CalDay={1}&amp;gt;}Data)/2)*Count(CalDay))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;if [CalDay] is selected the calculation will be&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Count(Distinct(BedDaysPatientID))&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;((Sum(Data)/2)*Count(CalDay))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;How do i write the calculation based on the above?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Kev&lt;/P&gt;</description>
    <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
    <dc:creator>kev6brown</dc:creator>
    <dc:date>2020-11-25T16:16:04Z</dc:date>
    <item>
      <title>Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599120#M737224</link>
      <description>&lt;P&gt;I'm looking to create a gauge that works differently depending on what has been selected from the calendar.&lt;/P&gt;&lt;P&gt;so, if [CalMonth] is selected the calculation needs to be&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Count((BedDaysPatientID))&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;((Sum({&amp;lt;CalDay={1}&amp;gt;}Data)/2)*Count(CalDay))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;if [CalDay] is selected the calculation will be&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Count(Distinct(BedDaysPatientID))&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;((Sum(Data)/2)*Count(CalDay))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;How do i write the calculation based on the above?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Kev&lt;/P&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599120#M737224</guid>
      <dc:creator>kev6brown</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599124#M737225</link>
      <description>&lt;P&gt;if(GetSelectedCount(&lt;SPAN&gt;CalDay&lt;/SPAN&gt;)&amp;gt;0,&lt;STRONG&gt;Count(Distinct(BedDaysPatientID))&lt;/STRONG&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;STRONG&gt;((Sum(Data)/2)*Count(CalDay)),&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(&lt;SPAN&gt;CalMonth&lt;/SPAN&gt;)&amp;gt;0,&lt;STRONG&gt;Count((BedDaysPatientID))&lt;/STRONG&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;STRONG&gt;((Sum({&amp;lt;CalDay={1}&amp;gt;}Data)/2)*Count(CalDay))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;What will happen is when you select callmonth and callday it's gonna use callday calculation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope this works&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jul 2019 14:01:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599124#M737225</guid>
      <dc:creator>vmoreno2605</dc:creator>
      <dc:date>2019-07-04T14:01:56Z</dc:date>
    </item>
    <item>
      <title>Re: Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599127#M737226</link>
      <description>&lt;P&gt;sorry, i missed the last ")"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(&lt;SPAN&gt;CalDay&lt;/SPAN&gt;)&amp;gt;0,&lt;STRONG&gt;Count(Distinct(BedDaysPatientID))&lt;/STRONG&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;STRONG&gt;((Sum(Data)/2)*Count(CalDay)),&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(&lt;SPAN&gt;CalMonth&lt;/SPAN&gt;)&amp;gt;0,&lt;STRONG&gt;Count((BedDaysPatientID))&lt;/STRONG&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;STRONG&gt;((Sum({&amp;lt;CalDay={1}&amp;gt;}Data)/2)*Count(CalDay))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;) )&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jul 2019 14:03:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599127#M737226</guid>
      <dc:creator>vmoreno2605</dc:creator>
      <dc:date>2019-07-04T14:03:01Z</dc:date>
    </item>
    <item>
      <title>Re: Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599129#M737227</link>
      <description>&lt;P&gt;Superb, works perfectly, if I then want to add [CalYear]&amp;nbsp; as a third layer?&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jul 2019 14:08:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599129#M737227</guid>
      <dc:creator>kev6brown</dc:creator>
      <dc:date>2019-07-04T14:08:26Z</dc:date>
    </item>
    <item>
      <title>Re: Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599137#M737228</link>
      <description>&lt;P&gt;you just need to add another if like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(&lt;SPAN&gt;CalDay&lt;/SPAN&gt;)&amp;gt;0,&lt;STRONG&gt;Count(Distinct(BedDaysPatientID))&lt;/STRONG&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;STRONG&gt;((Sum(Data)/2)*Count(CalDay)),&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(&lt;SPAN&gt;CalMonth&lt;/SPAN&gt;)&amp;gt;0,&lt;STRONG&gt;Count((BedDaysPatientID))&lt;/STRONG&gt;&lt;STRONG&gt;/&lt;/STRONG&gt;&lt;STRONG&gt;((Sum({&amp;lt;CalDay={1}&amp;gt;}Data)/2)*Count(CalDay)),&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(CalYear)&amp;gt;0,/*YOUR CODE HERE*/&lt;/P&gt;&lt;P&gt;) ))&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jul 2019 14:24:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599137#M737228</guid>
      <dc:creator>vmoreno2605</dc:creator>
      <dc:date>2019-07-04T14:24:50Z</dc:date>
    </item>
    <item>
      <title>Re: Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599142#M737229</link>
      <description>&lt;P&gt;That's what I assumed but it didn't work. I'll take another look. thank you&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jul 2019 14:31:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599142#M737229</guid>
      <dc:creator>kev6brown</dc:creator>
      <dc:date>2019-07-04T14:31:04Z</dc:date>
    </item>
    <item>
      <title>Re: Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599372#M737230</link>
      <description>&lt;P&gt;So, this work brilliantly -&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(CalDay)&amp;gt;0,Count ({&amp;lt;WardCode={'Grattan'}&amp;gt;}Distinct(BedDaysPatientID)),&lt;BR /&gt;if(GetSelectedCount(CalMonth)&amp;gt;0,Count({&amp;lt;WardCode={'Grattan'}&amp;gt;}(BedDaysPatientID))))&lt;/P&gt;&lt;P&gt;However when I try to add CalYear&lt;/P&gt;&lt;P&gt;if(GetSelectedCount(CalDay)&amp;gt;0,Count ({&amp;lt;WardCode={'Grattan'}&amp;gt;}Distinct(BedDaysPatientID)),&lt;BR /&gt;if(GetSelectedCount(CalMonth)&amp;gt;0,Count({&amp;lt;WardCode={'Grattan'}&amp;gt;}(BedDaysPatientID))),&lt;BR /&gt;if(GetSelectedCount(CalYear)&amp;gt;0,Count({&amp;lt;WardCode={'Grattan'}&amp;gt;}(BedDaysPatientID))))&lt;/P&gt;&lt;P&gt;It doesn't work and I get an error in expression: If takes 2-3 parameters&lt;/P&gt;</description>
      <pubDate>Fri, 05 Jul 2019 10:02:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599372#M737230</guid>
      <dc:creator>kev6brown</dc:creator>
      <dc:date>2019-07-05T10:02:04Z</dc:date>
    </item>
    <item>
      <title>Re: Gauge</title>
      <link>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599412#M737231</link>
      <description>Try it like this&lt;BR /&gt;&lt;BR /&gt;if(GetSelectedCount(CalDay)&amp;gt;0,Count ({&amp;lt;WardCode={'Grattan'}&amp;gt;}Distinct(BedDaysPatientID)),&lt;BR /&gt;if(GetSelectedCount(CalMonth)&amp;gt;0,Count({&amp;lt;WardCode={'Grattan'}&amp;gt;}(BedDaysPatientID)), /*Only two ')', */&lt;BR /&gt;if(GetSelectedCount(CalYear)&amp;gt;0,Count({&amp;lt;WardCode={'Grattan'}&amp;gt;}(BedDaysPatientID)))))</description>
      <pubDate>Fri, 05 Jul 2019 11:55:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Gauge/m-p/1599412#M737231</guid>
      <dc:creator>vmoreno2605</dc:creator>
      <dc:date>2019-07-05T11:55:08Z</dc:date>
    </item>
  </channel>
</rss>

