<?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: Complex what if analysis on text fields in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493740#M184679</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not sure if I understand completely. Shouldn't COMPLETE_FLAG for PROV_ID DD be 'N'?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you assume Measure_1 complete for all providers, you need to check the other measures only and then add up if all measures are 'Y', right?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;maybe like&lt;/P&gt;&lt;P&gt;=sum(-1 * (MEASURE_2='Y') * (MEASURE_3='Y') * (MEASURE_4='Y') )&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 06 Sep 2013 13:17:51 GMT</pubDate>
    <dc:creator>swuehl</dc:creator>
    <dc:date>2013-09-06T13:17:51Z</dc:date>
    <item>
      <title>Complex what if analysis on text fields</title>
      <link>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493739#M184678</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a question about what if analysis on text based fields.&amp;nbsp; I've looked at numerous examples using number fields, and that all seems fairly straight forward, however in my case it's going to be a bit more challenging.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is what my data set looks like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" style="border: 1px solid #000000; width: 100%;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;PROV_ID&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;MEASURE_1&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;MEASURE_2&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;MEASURE_3&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;MEASURE_4&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;COMPLETE_FLAG&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;AA&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;BB&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;CC&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;DD&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Y&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;N&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would like to do analysis that says, what if Measure 1 was 'Y' for all providers, how many would be complete?&amp;nbsp; OR what is Measure 2 is 'Y' how many providers would be complete?&amp;nbsp; One of the challenging issues is the COMPLETE_FLAG is set in the data, so by just using a variable for one of the measures, that is not going to charge the complete flag.&amp;nbsp; I'm&amp;nbsp; guessing I need to calculate that flag on the fly depending on the variable value for each measure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be appreciated!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Sep 2013 13:12:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493739#M184678</guid>
      <dc:creator>phcaptjim</dc:creator>
      <dc:date>2013-09-06T13:12:03Z</dc:date>
    </item>
    <item>
      <title>Re: Complex what if analysis on text fields</title>
      <link>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493740#M184679</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not sure if I understand completely. Shouldn't COMPLETE_FLAG for PROV_ID DD be 'N'?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you assume Measure_1 complete for all providers, you need to check the other measures only and then add up if all measures are 'Y', right?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;maybe like&lt;/P&gt;&lt;P&gt;=sum(-1 * (MEASURE_2='Y') * (MEASURE_3='Y') * (MEASURE_4='Y') )&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Sep 2013 13:17:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493740#M184679</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2013-09-06T13:17:51Z</dc:date>
    </item>
    <item>
      <title>Re: Complex what if analysis on text fields</title>
      <link>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493741#M184680</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;PROV_ID DD should be 'N', sorry about that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your logic seems to make sense, let me try that in practice and see what happens.&amp;nbsp; This might be tricky in that I have about 40 measures to look at in my actual data model, I trimmed down my example to make it more practical for this forum.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Sep 2013 13:25:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493741#M184680</guid>
      <dc:creator>phcaptjim</dc:creator>
      <dc:date>2013-09-06T13:25:51Z</dc:date>
    </item>
    <item>
      <title>Re: Complex what if analysis on text fields</title>
      <link>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493742#M184681</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Another idea would be to prepare a table in your script, that holds all providers with exactely one measure being 'N' and the measure name that is 'N'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then, when you want to query 'what if measure1 is Y for all providers', just add up the providers in that table with 'measure1' set and add the count of COMPLETE_FLAG = 'Y'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;edit: attached a sample&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Sep 2013 13:35:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Complex-what-if-analysis-on-text-fields/m-p/493742#M184681</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2013-09-06T13:35:29Z</dc:date>
    </item>
  </channel>
</rss>

