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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

if a delivery has both status x and y in a table

Hi all,

i've got a table with order, amount, status and date.

I only want to count the amounts of the order if the order has both status x and y.

example:

Order amount status date

1 10 x 2009-02-03

1 10 y 2009-02-07

2 20 x 2009-05-01

3 30 x 2009-05-02

3 30 y 2009-06-30

Here it must only count the orders 1 and 3 (amount 10 and 30 )

How can i do this?

thanks,

Rey-man

1 Solution

Accepted Solutions
Not applicable
Author

Hi,

I`m not sure how much this attached application is going to help you.

Check the attachment and let me know if it works for your scenario.

- Sridhar Yes

View solution in original post

4 Replies
Not applicable
Author

Hi,

You can try with this if(count(total <Order> distinct status)>1,sum(amount))

Not applicable
Author

Hi Ste82,

it would be possible if it has only 2 different statusses. But there can be 10000 different statusses. I only want to sum the amounts if the x and y status are in the table

Not applicable
Author

Hi,

I`m not sure how much this attached application is going to help you.

Check the attachment and let me know if it works for your scenario.

- Sridhar Yes

Not applicable
Author

Thanks Sridhar,

this is the solution I needed.

Thanks a lot