Need Help based on the given scenario

kriszpm

New Member
Joined
Dec 19, 2018
Messages
6
Hi,

I need to prepare a output based on the below table:

USER_IDTypeTime Stamp
User_10Dec-12-2018 19:53
User_10Dec-12-2018 19:53
User_10Dec-12-2018 19:57
User_10Dec-19-2018 18:30
User_10Dec-19-2018 18:31
User_10Dec-19-2018 18:32
User_10Dec-19-2018 18:33
User_11Dec-19-2018 18:35
User_20Dec-12-2018 17:36
User_20Dec-12-2018 17:37
User_20Dec-12-2018 19:12
User_21Dec-12-2018 19:15
User_30Dec-13-2018 0:47
User_30Dec-13-2018 0:47
User_30Dec-13-2018 0:48
User_30Dec-18-2018 2:22
User_30Dec-15-2018 14:01
User_30Dec-15-2018 14:01
User_30Dec-15-2018 14:01
User_30Dec-15-2018 14:02
User_30Dec-31-2018 0:55
User_30Dec-31-2018 0:55
User_31Dec-31-2018 0:55
User_30Dec-31-2018 0:59
User_31Dec-31-2018 2:30

<tbody>
</tbody>

Basically, I need the Time Difference from the 1st Type-0 and 1st Type-1 for the specific User.
And then if the user has multiple Type-1s, another record should be there the Time Stamp of Type-0 should be next one to the earlier Type-1 TimeStamp.

Below is the out of above table:

UserIDTime Stamp of Type 0Time Stamp of Type 1Time Difference
User_1Dec-12-2018 19:53Dec-19-2018 18:356 days 22 hrs 41 mins
User_2Dec-12-2018 17:36Dec-12-2018 19:150 days 1 hrs 38 mins
User_3Dec-13-2018 0:47Dec-31-2018 0:5518 days 0 hrs 7 mins
User_3Dec-31-2018 2:59Dec-31-2018 8:300 days 5 hrs 31 mins

<tbody>
</tbody>



Thanks in advance.
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
Hi Kriszpm,
are you looking for formulas, VBA code or something else? Please post your efforts so far.
Cheers,
Koen
 
Upvote 0
Hi Kriszpm,
you forgot to post the code you already wrote yourself (see my signature).
Thanks,
Koen
 
Upvote 0

Forum statistics

Threads
1,215,863
Messages
6,127,394
Members
449,382
Latest member
DonnaRisso

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top