<?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 Bar chart sorting by expression in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Bar-chart-sorting-by-expression/m-p/2056604#M86776</link>
    <description>&lt;P&gt;Hello&lt;BR /&gt;got a barchart with two dimensions : Fiscal Year, and Region&lt;BR /&gt;in this barchart&amp;nbsp; I'm displaying the total by the above dimesions plus the values&amp;nbsp;&lt;BR /&gt;so the Region dimension is calculated dimension as follows: pick(Total,Region, 'Total')&lt;BR /&gt;Total is a dimension I created in the script from an inline table with two values 1, and 2&lt;BR /&gt;so far so good&lt;BR /&gt;&lt;BR /&gt;Now I want to sort the result not as acending / descending but custom as follows:&lt;BR /&gt;&lt;STRONG&gt;Match&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;(&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;Only({1} [BUSINESS_UNIT_DESC]),&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;'Canada','Latin America','United States'&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;,'BU1','BU2','BU3','BU4','BU5','AM',&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;'Central Europe','France Benelux','MEA','Nordics Russia','Southern Europe + Morocco','UKI','Total'&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm getting the following result:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ali_hijazi_0-1680589056732.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/104146iB56AF110396523FF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ali_hijazi_0-1680589056732.png" alt="ali_hijazi_0-1680589056732.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;but I want the Total to be placed on the far-right&lt;BR /&gt;so how can I update the formula of sorting to accoplish this&lt;/P&gt;</description>
    <pubDate>Tue, 04 Apr 2023 06:18:27 GMT</pubDate>
    <dc:creator>ali_hijazi</dc:creator>
    <dc:date>2023-04-04T06:18:27Z</dc:date>
    <item>
      <title>Bar chart sorting by expression</title>
      <link>https://community.qlik.com/t5/App-Development/Bar-chart-sorting-by-expression/m-p/2056604#M86776</link>
      <description>&lt;P&gt;Hello&lt;BR /&gt;got a barchart with two dimensions : Fiscal Year, and Region&lt;BR /&gt;in this barchart&amp;nbsp; I'm displaying the total by the above dimesions plus the values&amp;nbsp;&lt;BR /&gt;so the Region dimension is calculated dimension as follows: pick(Total,Region, 'Total')&lt;BR /&gt;Total is a dimension I created in the script from an inline table with two values 1, and 2&lt;BR /&gt;so far so good&lt;BR /&gt;&lt;BR /&gt;Now I want to sort the result not as acending / descending but custom as follows:&lt;BR /&gt;&lt;STRONG&gt;Match&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;(&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;Only({1} [BUSINESS_UNIT_DESC]),&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;'Canada','Latin America','United States'&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;,'BU1','BU2','BU3','BU4','BU5','AM',&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;'Central Europe','France Benelux','MEA','Nordics Russia','Southern Europe + Morocco','UKI','Total'&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm getting the following result:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ali_hijazi_0-1680589056732.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/104146iB56AF110396523FF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ali_hijazi_0-1680589056732.png" alt="ali_hijazi_0-1680589056732.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;but I want the Total to be placed on the far-right&lt;BR /&gt;so how can I update the formula of sorting to accoplish this&lt;/P&gt;</description>
      <pubDate>Tue, 04 Apr 2023 06:18:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Bar-chart-sorting-by-expression/m-p/2056604#M86776</guid>
      <dc:creator>ali_hijazi</dc:creator>
      <dc:date>2023-04-04T06:18:27Z</dc:date>
    </item>
  </channel>
</rss>

