Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Keyuser
Contributor
Contributor

Ident values per delivery

Hy!

I have following table:

deliverycountry
123GB
123GB
123GB
123GB
455IT
455IT
455FR
455IT
455FR
1234DE
1234DE
1234DE
1234DE

 

Would like to recognize if the delivery only took place in one country:

deliverydelivery in one country?
123true
455false
1234true

 

Do you have an idea for me?

Thank you!

4 Replies
sergio0592
Specialist III
Specialist III

Hi,

As expression try with:

if(count(TOTAL <delivery> distinct country)=1,'True','False')
Keyuser
Contributor
Contributor
Author

And if I need this in the script?
Keyuser
Contributor
Contributor
Author

Any idea?

Need a solution in the script instead in expression 🙂

 

THANK YOU!

sergio0592
Specialist III
Specialist III

In script statement, try with :

TABLE:
LOAD *
INLINE [
id,delivery,country
1,123,	GB
2,123,  GB
3,123,	GB
4,123,	GB
5,455,	IT
6,455,	IT
7,455,	FR
8,455,	IT
9,455,	FR
10,1234,	DE
11,1234,	DE
12,1234,	DE
13,1234,	DE
];


TABLE2:
load
if(count (distinct country)=1,'true','false') as delivery_in_one_country?,
delivery
resident TABLE
group by delivery;