Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Subtracting Dates to determine Progress

Hi

I would like to calculate number of days on each WP Status. (Ageing per WP Status)

I have a Progress date when the workflow started and also
a WP ProgressID. Also a Created Date when the incident stated.

I basically need to take the lowest progress ID’s Progress date. Look at when the following one started – Then subtract the time diff.

Do you know how to structure this?

Thank you

Reference
  No
WP Created DateWP Progress DateWP StatusWP ProgressID=[WP
  ProgressDate]-[WP CreatedDate]
-
12016-05-16
  17:39
2016-05-23
  10:59
CLOSED68167.0
12016-05-16
  17:39
2016-05-23
  10:57
FINALIZE68137.0
12016-05-16
  17:39
2016-05-17
  9:00
UPDATE57701.0
12016-05-16
  17:39
2016-05-17
  9:00
VERIFY57691.0
12016-05-16
  17:39
2016-05-16
  17:39
NEW INCIDENT55970.0
3 Replies
sunny_talwar

May be this:

[WP Progress Date] - FirstSortedValue(TOTAL <[Refrence No]> [WP Progress Date], [WP ProgressID])

With Reference No and WP ProgressID as dimension

sunny_talwar

Or are you trying to create Created date in the script?

Anonymous
Not applicable
Author

Hi Sunny

Thanks for your speedy reply, but I had internet issues so only getting back to you now.

I'm happy with  a backend or frontend expression that will solve this.

The expression you gave gives me the same answer as WP Progress Date - WP Created Date


What I do need is actually days on each WP Status.

This should take the lowest WP Progress Date/ID look at the next WP Progress Date and return the number of days on each WP Status

So by definition WP Progress Date is the Date where the WP Status stated.

  • So if you subtract the next WP Progress Date from the current WP Progress Date you should get the days on each status.

Is a backend or frontend script better for this and do you have a solution???

Kind regards