Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

quser_learn
New Contributor III

Intersection / Set analysis

I need some help with the following: My goal is to find clients who bought Cat1 product also bought Cat2 products.

1. I have the data in one table as give below:

Prod CatProd Sub CatClient AddMySalesTeamSales
Cat1Prod1Client1100100
Cat1Other ProductsClient10200
Cat2Prod3ClentX100100
Cat2Other ProductsClient10400
Cat2Prod4Client150100

I need a output as the followng :

After selecting Cat1, I need to show only the following record. Any suggestions?

Cat2Client150500

 

thanks !

1 Solution

Accepted Solutions

Re: Intersection / Set analysis

See attached qvw.


talk is cheap, supply exceeds demand
4 Replies

Re: Intersection / Set analysis

See attached qvw.


talk is cheap, supply exceeds demand
quser_learn
New Contributor III

Re: Intersection / Set analysis

This is great ! How do I add one more field called "zip code" in addition to ClientAdd if required. (See below)

Is the following correct? or do I have to use some other operator?

({<[Prod Cat]={'Cat2'},[Client Add]=p({<[Prod Cat]=p([Prod Cat])>}[Client Add]),[Zip Code]=p({<[Prod Cat]=p([Prod Cat])>}[Zip Code])>}TeamSales)

Re: Intersection / Set analysis

I don't understand what you're trying to do. Can you explain what the result should be and why?


talk is cheap, supply exceeds demand
quser_learn
New Contributor III

Re: Intersection / Set analysis

If I had an additional column called zip and would like to still get the same result.

Prod CatProd Sub CatClient AddZipMySalesTeamSales
Cat1Prod1Client110001100100
Cat1Other ProductsClient1100010200
Cat2Prod3ClentX10009100100
Cat2Other ProductsClient1100010400
Cat2Prod4Client11000150100

Result:

Cat2Client11000150500
Community Browser