Skip to main content

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
CUSTOMERS ONLY: Now accepting customer applications for the 2023 Luminary Program: SUBMIT NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Shafiqur_Khan
Contributor II
Contributor II

How to sum the results of substraction between two columns?

Hello!

I have two columns named 'Created' and 'Terminated date'. I have done the substraction as below :

Load
  [Change ID],
 Date(floor([Created])) AS Created_Date,
  Month(Date(floor([Created]))) as Created_Month,
 Dual('Q'&Ceil(Month(Date(floor([Created])))/3),Ceil(Month(Date(floor([Created])))/3)) as Created_Quarter,
  [Termination date] - Date(floor([Created])) AS Termination_timelapse
 
Resident main;

 

Now, I want to sum the values in 'Termination_timelapse' and show that result through bar chart.

Any idea how to do that?

Thank you very much!

Labels (2)
1 Solution

Accepted Solutions
jonathandienst
Partner - Champion III
Partner - Champion III

Just use Sum(Termination_timelapse) as an expression and use the required dimension(s).

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

View solution in original post

3 Replies
Anil_Babu_Samineni

I would think this way?

Num([Termination date]) - Num(Date(floor([Created]))) AS Termination_timelapse

Then Create Bar Chart

Dimension : Termination_timelapse

Expression : Sum(Termination_timelapse)

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
jonathandienst
Partner - Champion III
Partner - Champion III

Just use Sum(Termination_timelapse) as an expression and use the required dimension(s).

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Shafiqur_Khan
Contributor II
Contributor II
Author

Thanks, worked perfectly!