<?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: Lookup between values within script (Qlik on Cloud, not QlikView) in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511979#M105167</link>
    <description>&lt;P&gt;Thanks&amp;nbsp;&lt;A href="https://community.qlik.com/t5/user/viewprofilepage/user-id/6148" target="_self"&gt;&lt;SPAN class=""&gt;rwunderlich&lt;/SPAN&gt;&lt;/A&gt;, I should have taken more time reading IntervalMatch documentation!&lt;BR /&gt;Just a little bit of tweaking gave exactly what I needed.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Set boundaryTolerance = 0.0001;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;[OutputVals]:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Load * Inline&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[LowerBound,Output&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;0,150&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;51,125&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;64,150&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;75,200&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;111,125&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;136,150&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;175,200&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;1000000&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;[BoundsMap]:Mapping Load [LowerBound],[Output] Resident [OutputVals];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[InputVals]:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Load * Inline&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[Input&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;0&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;3&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;48&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;50&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;53&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;64&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;67&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;70.123&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;120&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;160&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;210&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;// IntervalMatch adds the correct LowerBound and UpperBound values against the Input values&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Left Join([InputVals])&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;IntervalMatch ([Input]) Load&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[LowerBound],&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Peek('LowerBound', RecNo(), 'OutputVals')-$(boundaryTolerance) as [UpperBound]&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Resident [OutputVals];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;// Now mapping can be applied to those LowerBound values&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Left Join([InputVals]) Load [LowerBound], ApplyMap('BoundsMap',[LowerBound]) As [Output] Resident [OutputVals];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Drop Table [OutputVals];&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Drop Fields [LowerBound],[UpperBound];&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 28 Mar 2025 12:57:32 GMT</pubDate>
    <dc:creator>StephenDunn</dc:creator>
    <dc:date>2025-03-28T12:57:32Z</dc:date>
    <item>
      <title>Lookup between values within script (Qlik on Cloud, not QlikView)</title>
      <link>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511920#M105153</link>
      <description>&lt;P&gt;Given a table such as this&lt;/P&gt;&lt;P&gt;[Example]:&lt;BR /&gt;Load * Inline&lt;BR /&gt;[LowerBound,Result&lt;BR /&gt;0,150&lt;BR /&gt;51,125&lt;BR /&gt;64,150&lt;BR /&gt;75,200&lt;BR /&gt;111,125&lt;BR /&gt;136,150&lt;BR /&gt;175,200&lt;BR /&gt;211,200&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;Is it possible (without expanding the table to include every possible value) to do a lookup, such that looking up 70.123 in this table will return 150?&amp;nbsp; The lookup functions I can find all seem to require an exact match or a string pattern.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 27 Mar 2025 16:48:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511920#M105153</guid>
      <dc:creator>StephenDunn</dc:creator>
      <dc:date>2025-03-27T16:48:02Z</dc:date>
    </item>
    <item>
      <title>Re: Lookup between values within script (Qlik on Cloud, not QlikView)</title>
      <link>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511924#M105155</link>
      <description>&lt;P&gt;Try this&amp;nbsp;&lt;/P&gt;&lt;P&gt;MapResults:&lt;/P&gt;&lt;P&gt;MAPPING LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; LowerBound,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; Result&lt;/P&gt;&lt;P&gt;INLINE [&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; LowerBound, Result&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 0, 150&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 51, 125&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 64, 150&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 75, 200&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 111, 125&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 136, 150&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 175, 200&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; 211, 200&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;Data:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; Value,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; ApplyMap('MapResults', Floor(Value / 50) * 50, Null()) AS MappedResult&lt;/P&gt;&lt;P&gt;INLINE [&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; Value&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 70.123&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 120&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 160&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; 210&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;</description>
      <pubDate>Thu, 27 Mar 2025 16:57:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511924#M105155</guid>
      <dc:creator>Chanty4u</dc:creator>
      <dc:date>2025-03-27T16:57:03Z</dc:date>
    </item>
    <item>
      <title>Re: Lookup between values within script (Qlik on Cloud, not QlikView)</title>
      <link>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511928#M105157</link>
      <description>&lt;P&gt;I think the trick would be to generate an upper bound in the Example table and then use IntervalMatch(). Like this:&lt;/P&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;[Example]:&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Load *&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Inline [&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;LowerBound,Result&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;0,150&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;51,125&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;64,150&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;75,200&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;111,125&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;136,150&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;175,200&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;211,200&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;];&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Join (Example)&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Load&amp;nbsp;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;&amp;nbsp; LowerBound,&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;&amp;nbsp; Peek('LowerBound', RecNo(), 'Example') as UpperBound&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Resident Example;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Data:&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Load&lt;/FONT&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;&amp;nbsp;Value&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;INLINE [&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp; Value&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp; 70.123&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp; 120&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp; 160&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;&amp;nbsp; &amp;nbsp; 210&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;];&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Left Join(Data)&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;IntervalMatch (Value)&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;LOAD LowerBound, UpperBound&amp;nbsp;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;FONT face="courier new,courier"&gt;Resident Example;&lt;/FONT&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;That will leave you with a Syn key that you can get rid of depending on what your actual model looks like.&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;-Rob&lt;BR /&gt;&lt;A href="http://www.easyqlik.com" target="_blank"&gt;http://www.easyqlik.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://masterssummit.com" target="_blank"&gt;http://masterssummit.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://qlikviewcookbook.com" target="_blank"&gt;http://qlikviewcookbook.com&lt;/A&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 27 Mar 2025 19:00:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511928#M105157</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2025-03-27T19:00:39Z</dc:date>
    </item>
    <item>
      <title>Re: Lookup between values within script (Qlik on Cloud, not QlikView)</title>
      <link>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511979#M105167</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;A href="https://community.qlik.com/t5/user/viewprofilepage/user-id/6148" target="_self"&gt;&lt;SPAN class=""&gt;rwunderlich&lt;/SPAN&gt;&lt;/A&gt;, I should have taken more time reading IntervalMatch documentation!&lt;BR /&gt;Just a little bit of tweaking gave exactly what I needed.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Set boundaryTolerance = 0.0001;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;[OutputVals]:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Load * Inline&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[LowerBound,Output&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;0,150&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;51,125&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;64,150&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;75,200&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;111,125&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;136,150&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;175,200&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;1000000&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;[BoundsMap]:Mapping Load [LowerBound],[Output] Resident [OutputVals];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[InputVals]:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Load * Inline&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[Input&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;0&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;3&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;48&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;50&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;53&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;64&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;67&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;70.123&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;120&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;160&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;210&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;// IntervalMatch adds the correct LowerBound and UpperBound values against the Input values&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Left Join([InputVals])&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;IntervalMatch ([Input]) Load&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;[LowerBound],&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Peek('LowerBound', RecNo(), 'OutputVals')-$(boundaryTolerance) as [UpperBound]&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Resident [OutputVals];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;// Now mapping can be applied to those LowerBound values&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Left Join([InputVals]) Load [LowerBound], ApplyMap('BoundsMap',[LowerBound]) As [Output] Resident [OutputVals];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Drop Table [OutputVals];&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;Drop Fields [LowerBound],[UpperBound];&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Mar 2025 12:57:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Lookup-between-values-within-script-Qlik-on-Cloud-not-QlikView/m-p/2511979#M105167</guid>
      <dc:creator>StephenDunn</dc:creator>
      <dc:date>2025-03-28T12:57:32Z</dc:date>
    </item>
  </channel>
</rss>

