Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Sum if

I need to make a sum for different options.

Example:

The order for account A is 10. We have failed to deliver 1, which is marked as "failed". (in the tabel 2 rows, commom dimensions are accountnr and ordernr)

The order for account B is 100. We have delivered all.

I need the following result:

                    Ordered     Delivered     Not delivered

Account A     10               9               1

Account B     100          100               0

How can I proceed? Best to use Rowno or Recno? Or something else?

Thanks!

1 Solution

Accepted Solutions
rajni_batra
Specialist
Specialist

Here u Go.. Hope to Help!!!

View solution in original post

14 Replies
Jason_Michaelides
Luminary Alumni
Luminary Alumni

Please provide example of the input data.

Not applicable
Author

CustomerOrdered/ deliveredArticleDateAmount
Customer AOrdered10526-sep-121
Customer ANot delivered10526-sep-12-1
Customer BOrdered10526-sep-121
Customer BNot delivered10526-sep-12-1
Customer COrdered10526-sep-121
Customer CNot delivered10526-sep-12-1
Customer DOrdered10526-sep-121
Customer DNot delivered10526-sep-12-1
Customer EOrdered10526-sep-121
Customer ENot delivered10526-sep-12-1
Customer FOrdered10526-sep-121
Customer FNot delivered10526-sep-12-1
Customer GOrdered10526-sep-121
Customer GNot delivered10526-sep-12-1
Customer HOrdered10526-sep-121
Customer HNot delivered10526-sep-12-1
Not applicable
Author

Here you go

rajni_batra
Specialist
Specialist

What output do u want??? no. of products deliverd/Not delivered?? do u have any field regarding that??

Jason_Michaelides
Luminary Alumni
Luminary Alumni

Where do you get the number ordered from in there?

Not applicable
Author

The output I need is in the following format:

Customer     Amount ordered     Amount not delivered

Customer A          1                    -1

Customer B          1                    -1

Customer C          1                    -1

So the second line per customer needs to be added to the first line. In this example it's only 2 lines per customer, but it can be more.

Not applicable
Author

The output I need is in the following format:

Customer     Amount ordered     Amount not delivered

Customer A          1                    -1

Customer B          1                    -1

Customer C          1                    -1

So the second line per customer needs to be added to the first line. In this example it's only 2 lines per customer, but it can be more.

Not applicable
Author

The output I need is in the following format:

Customer     Amount ordered     Amount not delivered

Customer A          1                    -1

Customer B          1                    -1

Customer C          1                    -1

So the second line per customer needs to be added to the first line. In this example it's only 2 lines per customer, but it can be more.

Not applicable
Author

The output I need is in the following format:

Customer     Amount ordered     Amount not delivered

Customer A          1                    -1

Customer B          1                    -1

Customer C          1                    -1

So the second line per customer needs to be added to the first line. In this example it's only 2 lines per customer, but it can be more.