Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
chriscools
Creator II
Creator II

expression: how to include all statusses of an order but exclude 1 substatus?

Hello,

i am trying to make a list of available stock in the warehouse and therefore i need to calcute the amount of outstanding orders per article.

I do it with this expression:

sum({<OrderStatus={"On hold", "Placed" }>} OrderPriceUnitNet * OrderQtyOpen)

But Orderstatus "on hold" has a few substatusses with fielname "OnHoldReason":

-untreated

-waiting for client

-waiting for payment

-quotation

Now i don't want to take all the substatusses into consideration, the "quotation" i don't want to count.

How would i have to adapt the expression so it doesn't take the "OnHoldReason" "quotation"?

I think i  can't just make the expression with all the "OnHoldReason" i want , because for "Orderstatus" pladed this value is null.

Anybody can set me in the right direction?

thanx!

Chris

1 Reply
jonathandienst
Partner - Champion III
Partner - Champion III

Hi

sum({<OrderStatus={'On hold'}, OnHoldReason-={'Quotation'}> + <OrderStatus={"Placed"}>} OrderPriceUnitNet * OrderQtyOpen)

(The -= will register as a syntax error in the editor, but this is a bug in the expression editor and the expression will work)

HTH

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein