4 Replies Latest reply: May 4, 2017 4:53 AM by Luis Carmona Martínez

# Intersection Operator * Qlik Sense

Hi. I am using Qlik Sense 3.1 and I am not finding a solution for the  Intersection of two sets.

I just need to get the SUM of Sales of Costumers who have bought Product A and also bought Product B. Although the sales of product A and B will not be on the same row of the data file.

Is that feasable? I have been able to use the "+" operator, that shows the ones that have bought Product A or B. But I need to use the "*" operator to just narrow it.

Arguments:

OperatorDescription
+Union. This binary operation returns a set consisting of the records that belong to any of the two set operands.
-Exclusion. This binary operation returns a set of the records that belong to the first but not the other of the two set operands. Also, when used as a unary operator, it returns the complement set.
*Intersection. This binary operation returns a set consisting of the records that belong to both of the two set operands.
/Symmetric difference (XOR). This binary operation returns a set consisting of the records that belong to either, but not both of the two set operands.

Are all set operator working in Sense as in QView?

Formula with the Problem:

Result Obtained: 0

Sum(

{<

Article_Set={"ProductA*"}

>*<

Article_Set={"ProductB*"}

>}

[Sales])

• ###### Re: Intersection Operator * Qlik Sense

Sum({<Customer = p({<Article_Set={"ProductA*"}>})*p({<Article_Set={"ProductB*"}>})>}[Sales])

• ###### Re: Intersection Operator * Qlik Sense

Hi Sunny,

Thanks for your quick response. Looks like there is some problem with the translation of your syntax to mine.

Error displayed:

error in set modifier element function name: Por E expected

Sum({<ICC = P({Grupo_Articulo_Report_Desc={"Le*"}>})*P({<Grupo_Articulo_Report_Desc={"Mon*"}>})>}[Importe con IVA])

Luis

• ###### Re: Intersection Operator * Qlik Sense

This

Sum({<ICC = P({<Grupo_Articulo_Report_Desc={"Le*"}>})*P({<Grupo_Articulo_Report_Desc={"Mon*"}>})>}[Importe con IVA])

• ###### Re: Intersection Operator * Qlik Sense

Thanks for the answer, I have tested the formula and works perfect!!

Thanks a lot!!