Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Not applicable

set analysis. Unable to filter, keep getting sum of all record.

Hi Qlikers,

I have manage to get several set analysis expression to work correctly, but there's something weird about this weird expression, 

Sum(${<Inventory_Date={"$(=DATE(MAX(Inventory_Date), 'DD/MM/YYYY'))"},Shipment_Qty_Type={"Closed"}, dateSet={"$(=MonthName(addmonths(MAX(dateSet),-1)))"},QUANTITY_UM={"CTN"}>}total_qty)

The objective of this expression is to get the previous month's shipped_qty, but somehow, what I'm getting is always the sum of all of the records.

The below is the raw data. Actual Ship Date in the load script is loaded as,

"MonthName(Date("Actual Ship Date", 'DD-MM-YYYY')) as dateSet"

I have attach the app as well. please help ;(

1 Solution

Accepted Solutions
MVP
MVP

Re: set analysis. Unable to filter, keep getting sum of all record.

You have a misplaced $ sign:

Sum({$<Inventory_Date={"$(=DATE(MAX(Inventory_Date), 'DD/MM/YYYY'))"},Shipment_Qty_Type={"Closed"}, dateSet={"$(=MonthName(addmonths(MAX(dateSet),-1)))"},QUANTITY_UM={"CTN"}>}total_qty)

4 Replies
Not applicable

Re: set analysis. Unable to filter, keep getting sum of all record.

also, forgot to mention, that expression is used in the prev_average located at top-right of the app. thx.

MVP
MVP

Re: set analysis. Unable to filter, keep getting sum of all record.

You have a misplaced $ sign:

Sum({$<Inventory_Date={"$(=DATE(MAX(Inventory_Date), 'DD/MM/YYYY'))"},Shipment_Qty_Type={"Closed"}, dateSet={"$(=MonthName(addmonths(MAX(dateSet),-1)))"},QUANTITY_UM={"CTN"}>}total_qty)

Not applicable

Re: set analysis. Unable to filter, keep getting sum of all record.

haha. Thank you once again Sunny. I don't believe this, I have been scanning for SO MANY TIMES for misplaces and errors. really thanks Sunny.

MVP
MVP

Re: set analysis. Unable to filter, keep getting sum of all record.

Hahahaha I have been scratching my head for last 15-20 minutes to check what is going wrong . Not very used to using Qlik Sense so there was the challenge of finding where to find all the things

But I am glad we were ultimately able to resolve it

Community Browser