Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

anushahegde
New Contributor III

Include in set analysis

Hi all,

Concat(Distinct{<Include = {'Y'}>}chr(39) & [Country Id] & chr(39),',')

Include is not a field name.

I wanted to understand what does Include=Y do in the set analysis? Can anyone help me here?

Thanks in advance,

Anusha

10 Replies
YoussefBelloum
Esteemed Contributor

Re: Include in set analysis

Hi,

your expression make sense only if INCLUDE is a field on your datamodel.. otherwise you will see that the expression is highlighted in red..

Highlighted
anushahegde
New Contributor III

Re: Include in set analysis

Hi,

Include is not in the data model. It is not a fieldname.Include.PNGed.

rittermd
Honored Contributor

Re: Include in set analysis

If Include was a field in your data then set analysis would limit this calculation to only rows where Include = 'Y'

keerthika
Contributor II

Re: Include in set analysis

Yes, If include is a field the result record fetch only the 'Y' records in Include field.

otherwise refer this link https://help.qlik.com/en-US/qlikview/November2017/Subsystems/Client/Content/Scripting/SystemVariable...

It will not generate a error even though it was not a field , it fails silently 

anushahegde
New Contributor III

Re: Include in set analysis

Yes. But that's not the case here.

This expression gives me the country id of the selected country within the single quotes as the output - '184'

When I removed Include = Y, It gives some wrong value.

Wanted to know the significance of Include here.

anushahegde
New Contributor III

Re: Include in set analysis

Hi,

I know about Include and must_include.

Any idea what is it doing in the set analysis I mentioned?

YoussefBelloum
Esteemed Contributor

Re: Include in set analysis

I see,. neved used include in a set analysis... maybe stalwar1‌ can take a look here ?

Re: Include in set analysis

Does it make any difference if you exclude it? I am guessing it might not be doing anything?

MVP
MVP

Re: Include in set analysis

There are two possibilities:

(1) Include is a field name and the expression will be filtered to value = Y

(2) Include is not a field name, and the set expression part of the expression will fail silently (ie will be ignored).

Its one of these two. There is nothing else.

PS - it has nothing whatsoever to do with the script keywords include/must-include

Community Browser