<?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 Metric based on row value of a table in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Metric-based-on-row-value-of-a-table/m-p/1860920#M71042</link>
    <description>&lt;P&gt;Hello&lt;/P&gt;
&lt;P&gt;I have the following table&lt;/P&gt;
&lt;P&gt;CAR &amp;nbsp; &amp;nbsp;- &amp;nbsp; &amp;nbsp; MODEL &amp;nbsp; &amp;nbsp; - &amp;nbsp; COUNTRY&lt;/P&gt;
&lt;P&gt;Audi - A4 - Spain&lt;BR /&gt;Seat - Ibiza - England&lt;BR /&gt;...&lt;/P&gt;
&lt;P&gt;I want a new column with the total cars selled, based in the country of each row.&lt;/P&gt;
&lt;P&gt;I tried this expression and works:&amp;nbsp;Pick(1,MODEL)&lt;BR /&gt;The expression returns the model for each row of the table.&lt;BR /&gt;&lt;BR /&gt;But if I try this expression, doesn't work:&lt;BR /&gt;COUNT(TOTAL DISTINCT {&amp;lt;MODEL={'$(=Pick(1,MODEL))'}&amp;gt;} [Id Ad])&lt;/P&gt;
&lt;P&gt;How can I calculate a metric based on the value it has in each line of the table?&lt;/P&gt;
&lt;P&gt;Thank you so much.&lt;/P&gt;</description>
    <pubDate>Thu, 18 Nov 2021 11:19:17 GMT</pubDate>
    <dc:creator>danielgarciamej</dc:creator>
    <dc:date>2021-11-18T11:19:17Z</dc:date>
    <item>
      <title>Metric based on row value of a table</title>
      <link>https://community.qlik.com/t5/App-Development/Metric-based-on-row-value-of-a-table/m-p/1860920#M71042</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;
&lt;P&gt;I have the following table&lt;/P&gt;
&lt;P&gt;CAR &amp;nbsp; &amp;nbsp;- &amp;nbsp; &amp;nbsp; MODEL &amp;nbsp; &amp;nbsp; - &amp;nbsp; COUNTRY&lt;/P&gt;
&lt;P&gt;Audi - A4 - Spain&lt;BR /&gt;Seat - Ibiza - England&lt;BR /&gt;...&lt;/P&gt;
&lt;P&gt;I want a new column with the total cars selled, based in the country of each row.&lt;/P&gt;
&lt;P&gt;I tried this expression and works:&amp;nbsp;Pick(1,MODEL)&lt;BR /&gt;The expression returns the model for each row of the table.&lt;BR /&gt;&lt;BR /&gt;But if I try this expression, doesn't work:&lt;BR /&gt;COUNT(TOTAL DISTINCT {&amp;lt;MODEL={'$(=Pick(1,MODEL))'}&amp;gt;} [Id Ad])&lt;/P&gt;
&lt;P&gt;How can I calculate a metric based on the value it has in each line of the table?&lt;/P&gt;
&lt;P&gt;Thank you so much.&lt;/P&gt;</description>
      <pubDate>Thu, 18 Nov 2021 11:19:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Metric-based-on-row-value-of-a-table/m-p/1860920#M71042</guid>
      <dc:creator>danielgarciamej</dc:creator>
      <dc:date>2021-11-18T11:19:17Z</dc:date>
    </item>
  </channel>
</rss>

