<?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 Simple Question about max() function in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208241#M63674</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good Morning Everybody,&lt;/P&gt;&lt;P&gt;I've a field with counter number (for example Index) :&lt;/P&gt;&lt;P&gt;Index&lt;/P&gt;&lt;P&gt;123&lt;BR /&gt;160&lt;BR /&gt;176&lt;BR /&gt;180&lt;BR /&gt;250&lt;/P&gt;&lt;P&gt;If I do : "Variable = Max(Index)" I get 250 this is ok but if I do "Above(Index)" I get :&lt;/P&gt;&lt;P&gt;Above(Index)&lt;/P&gt;&lt;P&gt;-&lt;BR /&gt;123&lt;BR /&gt;160&lt;BR /&gt;176&lt;BR /&gt;180&lt;BR /&gt;250&lt;/P&gt;&lt;P&gt;and Max(Above(Index)) returns this '-'&lt;/P&gt;&lt;P&gt;The aim is to make a difference between Index and Above(Index)&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 12 Apr 2011 10:23:10 GMT</pubDate>
    <dc:creator />
    <dc:date>2011-04-12T10:23:10Z</dc:date>
    <item>
      <title>Simple Question about max() function</title>
      <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208237#M63670</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Everybody,&lt;/P&gt;&lt;P&gt;I want to change the color in bar chart as the following :&lt;/P&gt;&lt;P&gt;Red for the higher value and Green for the lower value&lt;/P&gt;&lt;P&gt;So, under bar chart properties &amp;gt;&amp;gt; Expressions &amp;gt;&amp;gt; "+" &amp;gt;&amp;gt; Background Color &amp;gt;&amp;gt; Definition I(ve written this :&lt;/P&gt;&lt;P&gt;if(data%Table-above(data%Table)=max(data%Table-above(data%Table)),LightRed()) but It doesn't work&lt;/P&gt;&lt;P&gt;However, if I write this :&lt;/P&gt;&lt;P&gt;if(data%Table-above(data%Table)=23,LightRed()) it works&lt;/P&gt;&lt;P&gt;Do you know what is wrong with max function ?&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 09:59:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208237#M63670</guid>
      <dc:creator />
      <dc:date>2011-04-11T09:59:54Z</dc:date>
    </item>
    <item>
      <title>Simple Question about max() function</title>
      <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208238#M63671</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear jeremy02,&lt;/P&gt;&lt;P&gt;first calculate the max function and store the value in a variable and then apply your expression.&lt;/P&gt;&lt;P&gt;I hope that might work.&lt;/P&gt;&lt;P&gt;TC &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 10:03:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208238#M63671</guid>
      <dc:creator>sushil353</dc:creator>
      <dc:date>2011-04-11T10:03:15Z</dc:date>
    </item>
    <item>
      <title>Simple Question about max() function</title>
      <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208239#M63672</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hi Sushi,&lt;/P&gt;&lt;P&gt;First, thank you to help me.&lt;/P&gt;&lt;P&gt;As you told me I have to do the following :&lt;/P&gt;&lt;P&gt;max_value = max(data%Table-above(data%Table))&lt;/P&gt;&lt;P&gt;if data%Table-above(data%Table)= max_value, lighred()&lt;/P&gt;&lt;P&gt;My question is to know where to do the first line ? Because I think that we can just add 1 expression at the same time no ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 10:34:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208239#M63672</guid>
      <dc:creator />
      <dc:date>2011-04-11T10:34:50Z</dc:date>
    </item>
    <item>
      <title>Simple Question about max() function</title>
      <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208240#M63673</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;ok the problem is that the expression "data%table - above(data%table)" return nothing&lt;/P&gt;&lt;P&gt;How can I get a field with this : NewField = Field(i) - Filed(i-1)&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 10:58:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208240#M63673</guid>
      <dc:creator />
      <dc:date>2011-04-11T10:58:56Z</dc:date>
    </item>
    <item>
      <title>Simple Question about max() function</title>
      <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208241#M63674</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good Morning Everybody,&lt;/P&gt;&lt;P&gt;I've a field with counter number (for example Index) :&lt;/P&gt;&lt;P&gt;Index&lt;/P&gt;&lt;P&gt;123&lt;BR /&gt;160&lt;BR /&gt;176&lt;BR /&gt;180&lt;BR /&gt;250&lt;/P&gt;&lt;P&gt;If I do : "Variable = Max(Index)" I get 250 this is ok but if I do "Above(Index)" I get :&lt;/P&gt;&lt;P&gt;Above(Index)&lt;/P&gt;&lt;P&gt;-&lt;BR /&gt;123&lt;BR /&gt;160&lt;BR /&gt;176&lt;BR /&gt;180&lt;BR /&gt;250&lt;/P&gt;&lt;P&gt;and Max(Above(Index)) returns this '-'&lt;/P&gt;&lt;P&gt;The aim is to make a difference between Index and Above(Index)&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Apr 2011 10:23:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208241#M63674</guid>
      <dc:creator />
      <dc:date>2011-04-12T10:23:10Z</dc:date>
    </item>
    <item>
      <title>Simple Question about max() function</title>
      <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208242#M63675</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In teh expression of the Background colour setting of your expression use the 'rank()' function to determine the top and bottom values and assign the colours required in much the same way as your initial example.&lt;/P&gt;&lt;P&gt;This method works for me and you don't need to get bogged down in variables.&lt;/P&gt;&lt;P&gt;Something along the lines of (unchecked):&lt;/P&gt;&lt;P&gt;=if(rank(Sum(Sales))=1,rgb(198,255,198),if(ranksum(Sales),4)=1,rgb(255,198,198),rgb(255,255,255)))&lt;/P&gt;&lt;P&gt;If you get stuck have a look in the help file.&lt;/P&gt;&lt;P&gt;Hope that helps,&lt;/P&gt;&lt;P&gt;Matt - Visual Analytics Ltd&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Apr 2011 10:53:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208242#M63675</guid>
      <dc:creator>matt_crowther</dc:creator>
      <dc:date>2011-04-12T10:53:26Z</dc:date>
    </item>
    <item>
      <title>Simple Question about max() function</title>
      <link>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208243#M63676</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've a question Matt :&lt;/P&gt;&lt;P&gt;This is the Field named "Index" and the return values of the expression rank(Index)&lt;/P&gt;&lt;P&gt;Is it normal that I get exactly the same ranking if I write rank(Index,0) or rank(Index,1) or rank(Index,2) ... ? According to the help no, do you knwo the reason ?&lt;/P&gt;&lt;P&gt;&lt;A href="http://community.qlik.com/cfs-file.ashx/__key/CommunityServer.Discussions.Components.Files/11/5758.help_5F00_rank.jpg"&gt;&lt;IMG alt="" border="0" src="http://community.qlik.com/resized-image.ashx/__size/550x0/__key/CommunityServer.Discussions.Components.Files/11/5758.help_5F00_rank.jpg" /&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Apr 2011 13:03:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Simple-Question-about-max-function/m-p/208243#M63676</guid>
      <dc:creator />
      <dc:date>2011-04-12T13:03:49Z</dc:date>
    </item>
  </channel>
</rss>

