Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Maximum/Minimum Number of Days a Job has been open?

Hello!

I am trying to find out the maximum number of days a Job has been open.

I have the following info:

JobNoCreatedDateFinishDateStatus
101/01/201505/01/2015Finished
203/01/201516/01/2015Finished
305/01/201520/01/2015Finished
401/01/2015Unresolved
502/01/201517/01/2015Unresolved.

I have some discrepancy in my data. So I would like to focus on Jobs that have the status of Finished only when finding the Min and Max.

How can I identify the shortest and longest number of days a Job has been open based on this?

4 Replies
maxgro
MVP
MVP

if you want in a text box

min or max of the difference (finish - created) by JobNo, with status finished

=min({$ <Status={Finished}>} aggr(FinishDate -CreatedDate,JobNo))

agomes1971
Specialist II
Specialist II

Hi,

expression for the difference days...

date#(FinishDate, 'DD/MM/YYYY') - Date#(CreatedDate, 'DD/MM/YYYY')



Min(date#(FinishDate, 'DD/MM/YYYY') - Date#(CreatedDate, 'DD/MM/YYYY'))


Max(date#(FinishDate, 'DD/MM/YYYY') - Date#(CreatedDate, 'DD/MM/YYYY'))


HTH


André Gomes

MarcoWedel

Hi,

one solution could be also:

=Min({$<Status={'Finished'}>} FinishDate-CreatedDate)

=Max({$<Status={'Finished'}>} FinishDate-CreatedDate)

QlikCommunity_Thread_149328_Pic2.JPG

QlikCommunity_Thread_149328_Pic1.JPG

hope this helps

regards

Marco

jagan
Luminary Alumni
Luminary Alumni

Hi,

Try like this

=Min({<Status={'Finished'}>} Floor(FinishDate-CreatedDate))

Hope this helps you.

Regards,

Jagan.