Skip to main content
Announcements
July 15, NEW Customer Portal: Initial launch will improve how you submit Support Cases. IMPORTANT DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
aveeeeeee7en
Specialist III
Specialist III

Date difference based on status

TICKETNUMBER

WORKSTATUS

MODIFIEDON

  1. 11.85318

CD1300000292734

Pending for Customer Approval

20/05/13

Pick Minimum Date

20/05/13

Maximum Date - Minimum Date

CD1300000292734

Pending for Customer Approval

21/05/13

CD1300000292734

Pending for Customer Approval

23/06/13

CD1300000292734

Customer Approved

01/06/13

Pick Maximum Date

01/06/13

CD1300000292734

Pending for Customer Approval

29/05/13

Pick Minimum Date1

29/05/13

Maximum Date1 - Minimum Date1

  1. 6.8136

CD1300000292734

Pending for Customer Approval

30/05/13

CD1300000292734

Pending for Customer Approval

03/06/13

CD1300000292734

Customer Approved

03/06/13

Pick Maximum Date1

CD1300000292734

Customer Approved

05/06/13

05/06/13

CD1300000292734

Pending for Customer Approval

17/06/13

Not to be used since after 'Pending for Customer Approval' there is no 'Customer Approval'. So, I don’t have to consider these cases.

CD1300000292734

Pending for Customer Approval

17/06/13

CD1300000292734

Pending for Customer Approval

19/06/13

CD1300000292734

Pending for Customer Approval

22/06/13

CD1300000292734

Pending for Customer Approval

26/06/13

CD1300000292734

Pending for Customer Approval

01/07/13

CD1300000292734

Pending for Customer Approval

04/07/13

CD1300000292734

Pending for Customer Approval

09/07/13

Total

  1. 18.6667

Need help on the above example.

4 Replies
swuehl
MVP
MVP

Have you looked into my suggested solution I posted to your previous thread?

aveeeeeee7en
Specialist III
Specialist III
Author

Yes Sir. I have seen your previous thread. That was wonderful but it was not giving me desired output.

Kindly help me on this.

adnan_rafiq
Partner - Creator II
Partner - Creator II

Hi,

when you reload data user group by.  it will be like

load Ticket_id,

      Status,

if(Status = 'Customer approval', Max(date) )as Maxdate,

if(Status <>' Customer Approval', Min(date))as Min_date

From File group by Ticket_id, Status ;

swuehl
MVP
MVP

well, I do get your desired output (as posted in your sample data), just loading your data with my suggested solution.

see attached.

Please exactly point out the issue with this solution.