MAx Date and Time

vmjan02

Well-known Member
Joined
Aug 15, 2012
Messages
1,059
Office Version
  1. 365
  2. 2021
  3. 2019
  4. 2016
  5. 2013
I have this column and nee dto find the max date and time in one function is there a way there may will be woth date and time,
any other function

TASK LAST UPDATE DATE
9/1/2023 21:11
9/1/2023 18:40
9/1/2023 15:01
9/1/2023 21:11
9/2/2023 14:46
9/4/2023 21:43
9/1/2023 19:47
9/2/2023 15:30
9/1/2023 21:57
9/3/2023 15:51
9/1/2023 18:53
9/1/2023 14:56
9/3/2023 15:33
9/2/2023 18:00
9/2/2023 16:35
9/3/2023 10:25
9/1/2023 21:11
9/4/2023 15:25
9/1/2023 20:24
9/1/2023 13:45
9/1/2023 21:11
9/1/2023 21:11
9/1/2023 2:23
9/1/2023 21:11
9/1/2023 21:11
9/1/2023 13:08
9/1/2023 19:10
9/1/2023 0:57
9/3/2023 11:01
9/1/2023 16:46
9/2/2023 20:17
9/1/2023 21:11
9/1/2023 21:11
9/3/2023 11:13
9/1/2023 21:05
9/1/2023 15:10
9/2/2023 15:23
9/1/2023 20:58
9/5/2023 14:37
9/1/2023 17:57
9/1/2023 20:11
9/1/2023 20:29
9/1/2023 21:11
9/1/2023 21:08
9/1/2023 17:12
9/1/2023 20:02
9/1/2023 21:08
 
Are you trying to achieve this? 9/3/23 10:25 (subtract something) = 9/2/2023 9:15

Then you need to subtract one day and one hour and 10 minutes. =MAX(A2:A48)-(1+(1/24)+(1/60/24))
 
Upvote 0

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.
With your data, that is not what is happening. I put a MAX function, and a MAX -1. How is this not what you are expecting?

Book1
AB
1TASK LAST UPDATE DATE9/5/2023 14:37
29/1/2023 21:119/4/2023 14:37
39/1/2023 18:40
49/1/2023 15:01
59/1/2023 21:11
69/2/2023 14:46
79/4/2023 21:43
89/1/2023 19:47
99/2/2023 15:30
109/1/2023 21:57
119/3/2023 15:51
129/1/2023 18:53
139/1/2023 14:56
149/3/2023 15:33
159/2/2023 18:00
169/2/2023 16:35
179/3/2023 10:25
189/1/2023 21:11
199/4/2023 15:25
209/1/2023 20:24
219/1/2023 13:45
229/1/2023 21:11
239/1/2023 21:11
249/1/2023 2:23
259/1/2023 21:11
269/1/2023 21:11
279/1/2023 13:08
289/1/2023 19:10
299/1/2023 0:57
309/3/2023 11:01
319/1/2023 16:46
329/2/2023 20:17
339/1/2023 21:11
349/1/2023 21:11
359/3/2023 11:13
369/1/2023 21:05
379/1/2023 15:10
389/2/2023 15:23
399/1/2023 20:58
409/5/2023 14:37
419/1/2023 17:57
429/1/2023 20:11
439/1/2023 20:29
449/1/2023 21:11
459/1/2023 21:08
469/1/2023 17:12
479/1/2023 20:02
489/1/2023 21:08
Sheet1
Cell Formulas
RangeFormula
B1B1=MAX(A2:A48)
B2B2=MAX(A2:A48)-1
 
Upvote 0
With your data, that is not what is happening. I put a MAX function, and a MAX -1. How is this not what you are expecting?

Book1
AB
1TASK LAST UPDATE DATE9/5/2023 14:37
29/1/2023 21:119/4/2023 14:37
39/1/2023 18:40
49/1/2023 15:01
59/1/2023 21:11
69/2/2023 14:46
79/4/2023 21:43
89/1/2023 19:47
99/2/2023 15:30
109/1/2023 21:57
119/3/2023 15:51
129/1/2023 18:53
139/1/2023 14:56
149/3/2023 15:33
159/2/2023 18:00
169/2/2023 16:35
179/3/2023 10:25
189/1/2023 21:11
199/4/2023 15:25
209/1/2023 20:24
219/1/2023 13:45
229/1/2023 21:11
239/1/2023 21:11
249/1/2023 2:23
259/1/2023 21:11
269/1/2023 21:11
279/1/2023 13:08
289/1/2023 19:10
299/1/2023 0:57
309/3/2023 11:01
319/1/2023 16:46
329/2/2023 20:17
339/1/2023 21:11
349/1/2023 21:11
359/3/2023 11:13
369/1/2023 21:05
379/1/2023 15:10
389/2/2023 15:23
399/1/2023 20:58
409/5/2023 14:37
419/1/2023 17:57
429/1/2023 20:11
439/1/2023 20:29
449/1/2023 21:11
459/1/2023 21:08
469/1/2023 17:12
479/1/2023 20:02
489/1/2023 21:08
Sheet1
Cell Formulas
RangeFormula
B1B1=MAX(A2:A48)
B2B2=MAX(A2:A48)-1

If we -1 day then it suld take the day and the time from the table

Book1
ABCDEF
1TASK LAST UPDATE DATE9/5/2023 14:37correct
29/1/2023 21:119/4/2023 14:37-19/4/2023 21:43This shuld be the result
39/1/2023 18:40
49/1/2023 15:01
59/1/2023 21:11
69/2/2023 14:46
79/4/2023 21:43
89/1/2023 19:47
99/2/2023 15:30
109/1/2023 21:57
119/3/2023 15:51
129/1/2023 18:53
139/1/2023 14:56
149/3/2023 15:33
159/2/2023 18:00
169/2/2023 16:35
179/3/2023 10:25
189/1/2023 21:11
199/4/2023 15:25
209/1/2023 20:24
219/1/2023 13:45
229/1/2023 21:11
239/1/2023 21:11
249/1/2023 2:23
259/1/2023 21:11
269/1/2023 21:11
279/1/2023 13:08
289/1/2023 19:10
299/1/2023 0:57
309/3/2023 11:01
319/1/2023 16:46
329/2/2023 20:17
339/1/2023 21:11
349/1/2023 21:11
359/3/2023 11:13
369/1/2023 21:05
379/1/2023 15:10
389/2/2023 15:23
399/1/2023 20:58
409/5/2023 14:37
419/1/2023 17:57
429/1/2023 20:11
Sheet1
Cell Formulas
RangeFormula
C1C1=MAX(A1:A42)
C2C2=MAX(A1:A42)-1
Named Ranges
NameRefers ToCells
_FilterDatabase=Sheet1!$A$1:$A$42C1:C2
 
Upvote 0
Are you trying to achieve this? 9/3/23 10:25 (subtract something) = 9/2/2023 9:15

Then you need to subtract one day and one hour and 10 minutes. =MAX(A2:A48)-(1+(1/24)+(1/60/24))

Try this in C2:

=LARGE(A2:A42,2)
large don't work,
I tried
VBA Code:
=VLOOKUP((MAX('All Ticket'!W:W)-1),'All Ticket'!W:W,1,0)
but no luck
 
Upvote 0
Try again, in C2:

=AGGREGATE(14,6,A2:A42/(INT(A2:A42)<INT(MAX(A2:A42))),1)
 
Upvote 0
Can you just show the arithmetic for how you get:
(9/4/2023 14:37) -1 = 9/4/2023 21:43
 
Last edited:
Upvote 0

Forum statistics

Threads
1,215,071
Messages
6,122,963
Members
449,094
Latest member
Anshu121

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