Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

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
Gysbert_Wassenaar

See attached qvw.


talk is cheap, supply exceeds demand

View solution in original post

4 Replies
Gysbert_Wassenaar

See attached qvw.


talk is cheap, supply exceeds demand
Anonymous
Not applicable
Author

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)

Gysbert_Wassenaar

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
Anonymous
Not applicable
Author

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