<?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 Set Analysis and concat in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193665#M503167</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="jive_text_macro jive_macro_quote" jivemacro="quote"&gt;&lt;BR /&gt;gordon.savage wrote:I agree it should be as simple as that, but I found that it also returned 0 and that started me off on the road to concat. Again I dont know why it doesnt work.&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Weird. Maybe this?&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({1&amp;lt;[Ordering Depot]=P(Depot)&amp;gt;} [Number Orders])&lt;/P&gt;&lt;P&gt;But it sounds like you have a working solution already. I agree that the concat() needs the extra characters, but at that point I'd have expected it to work. I've done it before, even if only in examples, and I'm not seeing anything wrong with your syntax on brief glance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 08 Sep 2010 18:00:15 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2010-09-08T18:00:15Z</dc:date>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193659#M503161</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I have a chart expression:&lt;/P&gt;&lt;P&gt;sum({1&amp;lt;[Ordering Depot]={'$(=concat(distinct Depot))'}&amp;gt;} [Number Orders])&lt;/P&gt;&lt;P&gt;but this always (incorrectly) returns 0&lt;/P&gt;&lt;P&gt;I am using the dollar-sign expansion so that it returns the results of the concat in single quotes as 'Depot' is a text field which may contain spaces.&lt;/P&gt;&lt;P&gt;If I create a chart and put any of these expressions into it:&lt;/P&gt;&lt;P&gt;=concat(distinct Depot)&lt;BR /&gt;$(=Year(Today()))&lt;BR /&gt;$(=concat(distinct Year(Today())))&lt;/P&gt;&lt;P&gt;they return the expected values but if I try&lt;/P&gt;&lt;P&gt;$(=concat(distinct Depot))&lt;/P&gt;&lt;P&gt;it returns nothing.&lt;/P&gt;&lt;P&gt;I am obviously missing something, but what?&lt;/P&gt;&lt;P&gt;Any help appreciated.&lt;/P&gt;&lt;P&gt;Gordon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Sep 2010 16:23:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193659#M503161</guid>
      <dc:creator />
      <dc:date>2010-09-08T16:23:01Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193660#M503162</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Gordon,&lt;/P&gt;&lt;P&gt;My guess is that since concat has no delimitator, is concatenating one field after another, and since they are text fields, they need a precedeing and trailing comma taht concat does not add, so&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;$(=chr(39) &amp;amp; Concat(distinct Año, chr(39) &amp;amp; ',' &amp;amp; chr(39)) &amp;amp; chr(39))&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;will do the trick.&lt;/P&gt;&lt;P&gt;Hope that helps!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Sep 2010 16:46:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193660#M503162</guid>
      <dc:creator>Miguel_Angel_Baeyens</dc:creator>
      <dc:date>2010-09-08T16:46:20Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193661#M503163</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you should be able to use another field as an element set:&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({1&amp;lt;[Ordering Depot]=Depot&amp;gt;} [Number Orders])&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Sep 2010 17:25:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193661#M503163</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2010-09-08T17:25:04Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193662#M503164</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Miguel,&lt;/P&gt;&lt;P&gt;Thanks very much for your reply.&lt;/P&gt;&lt;P&gt;I understand what you are saying but I couldnt get it to work:&lt;/P&gt;&lt;P&gt;sum({1&amp;lt;[Ordering Depot]={$(=chr(39) &amp;amp; Concat(distinct Depot, chr(39) &amp;amp; ',' &amp;amp; chr(39)) &amp;amp; chr(39))}&amp;gt;} [Number Orders])&lt;/P&gt;&lt;P&gt;I actually found 'only' works and here is my expression:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({1&amp;lt;[Ordering Depot]={'$(=only(Depot))'}&amp;gt;} [Number Orders])&lt;/P&gt;&lt;P&gt;I am still intrigued why concat doesnt though.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gordon&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Sep 2010 17:29:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193662#M503164</guid>
      <dc:creator />
      <dc:date>2010-09-08T17:29:55Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193663#M503165</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi John,&lt;/P&gt;&lt;P&gt;Thanks for your input.&lt;/P&gt;&lt;P&gt;I agree it should be as simple as that, but I found that it also returned 0 and that started me off on the road to concat. Again I dont know why it doesnt work.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gordon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Sep 2010 17:40:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193663#M503165</guid>
      <dc:creator />
      <dc:date>2010-09-08T17:40:53Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193664#M503166</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Gordon,&lt;/P&gt;&lt;P&gt;I'm probably missing something also. Anyway, you may try setting a variable with the whole analysis, say vAnalysis&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;'{' &amp;amp; chr(39) &amp;amp; Concat(distinct Depot, chr(39) &amp;amp; ',' &amp;amp; chr(39)) &amp;amp; chr(39) &amp;amp; '}'&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;and then in your expression&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;Sum({1&amp;lt; [Ordering Depot] = $(vAnalysis) &amp;gt;} [Number Orders])&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Might work. I also agree that John's expression might work and is cleaner by far, though.&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Sep 2010 17:54:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193664#M503166</guid>
      <dc:creator>Miguel_Angel_Baeyens</dc:creator>
      <dc:date>2010-09-08T17:54:56Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193665#M503167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="jive_text_macro jive_macro_quote" jivemacro="quote"&gt;&lt;BR /&gt;gordon.savage wrote:I agree it should be as simple as that, but I found that it also returned 0 and that started me off on the road to concat. Again I dont know why it doesnt work.&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Weird. Maybe this?&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;sum({1&amp;lt;[Ordering Depot]=P(Depot)&amp;gt;} [Number Orders])&lt;/P&gt;&lt;P&gt;But it sounds like you have a working solution already. I agree that the concat() needs the extra characters, but at that point I'd have expected it to work. I've done it before, even if only in examples, and I'm not seeing anything wrong with your syntax on brief glance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Sep 2010 18:00:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193665#M503167</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2010-09-08T18:00:15Z</dc:date>
    </item>
    <item>
      <title>Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193666#M503168</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Miguel/John,&lt;/P&gt;&lt;P&gt;Miguel - again nice thinking but the expression editor sees it as an error. I also tried changing the variable and removed the curly brackets and put them around the variable in the expression. The editor was happy this time but again nothing was returned.&lt;/P&gt;&lt;P&gt;John - the elemental function P() works great and one that I wasnt aware of.&lt;/P&gt;&lt;P&gt;Thanks for your inputs.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gordon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Sep 2010 11:06:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193666#M503168</guid>
      <dc:creator />
      <dc:date>2010-09-09T11:06:37Z</dc:date>
    </item>
    <item>
      <title>Re: Set Analysis and concat</title>
      <link>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193667#M503169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've a related problem.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/thread/90041"&gt;Set Analysis restrict months depending on other expression&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Could you give me some help, with your expertise?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Bruno&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Aug 2013 13:27:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-Analysis-and-concat/m-p/193667#M503169</guid>
      <dc:creator>bruno_m_santos</dc:creator>
      <dc:date>2013-08-23T13:27:50Z</dc:date>
    </item>
  </channel>
</rss>

