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

Only use lines in a table which has things in common

Hi everybody,

i'm very new to Qlick sense and have a specific Problem.

I got the table as follows:

Article     Country          Price

A            Germany          2

B            Germany          3

C            Germany          4

A            Spain               1

B            Spain               2

B            Italy                 1

C            Italy                 2

In the end i want to calculate the average Price for a certain product in every country, but only products which are sold in every country. In my easy example it would be only product "B", because it was sold in Germany, Italy and Spain. So Qlick sense should show me:

"Average Price in Germany: 3", "Average price in Italy 1" and so on in an additional column. The real data table is much bigger, but the approach should be the same. For this reason i have to use loops in my notation.

The approach in my mind looks as follows:

1.Filter all products which are sold in every country. For this i can add a additional column, set the value to 0 if its not sold in every country and hide these lines.

2.Calculate the average price for each country.

But i do not know how the notation must looks like. Every attempt i tried, it says "fault".

I'm already desperate. If would be so nice if somebody helps me:)


Thanks

4 Replies
Gysbert_Wassenaar

See attached qvf


talk is cheap, supply exceeds demand
Not applicable
Author

Tanks for your help.

If I try to open the file, it says "invalid visualization. The visualization was not found on the server: com-qliktech-simpletable".

Gysbert_Wassenaar

Ok, I used features you can't use yet. Try the attached qvf instead.


talk is cheap, supply exceeds demand
Not applicable
Author

It works, thanks.

But if a product is sold more than once in a country it doesn't work anymore. How can i fix that?